Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- EASE OF ACCESS SETTINGS
- local inColor = Color3.new(0.45, 0.65, 0.9)
- local outColor = Color3.new(0.75, 1, 1)
- local inTrans = 0.3
- local outTrans = 0.5
- local inSize = Vector3.new(4, 4, 4)
- local outSize = Vector3.new(7, 7, 7)
- local inMaterial = "Ice"
- local outMaterial = "Ice"
- local baseDamage = 20
- local hits = 3
- local lifetime = 2
- local postFirstLifetime = 1 -- lifetim of hits after first
- --[[
- Below is the attack function.
- DESC: Strikes X amount of times. Subsequent hits give SSneak speed instead of normal.
- --]]
- local function Use(...)
- local args = {...}
- local char = args[1].Character
- local torso = char.Torso
- local hum = char.Humanoid
- local Stats = require(game:GetService("ServerScriptService").Stats)
- local DamageMod = require(game:GetService("ServerScriptService").Libraries.DamageService)
- local myLevel = Stats.GetStat(args[1], char.BaseStat.Value)
- local mySpeed = char.BaseSpeed
- for i = 1, hits do
- local damage = math.random(1, 20) == 1 and baseDamage*2 or baseDamage -- reduced crit (the move is already kinda toxic)
- -- damage*=i
- -- In order to achieve the damage increase from TripleAxel, uncomment the above line.
- -- Part creation and some variables
- local inner = Instance.new("Part")
- inner.Color, inner.Size, inner.Transparency, inner.Material, inner.Massless, inner.CanCollide, inner.CFrame =
- inColor, inSize, inTrans, inMaterial, true, false, torso.CFrame
- inner.Parent = workspace
- local outer = Instance.new("Part")
- outer.Color, outer.Size, outer.Transparency, outer.Material, outer.Massless, outer.CanCollide, outer.CFrame =
- outColor, outSize, outTrans, outMaterial, true, false, torso.CFrame
- outer.Parent = workspace
- local oplib = require(game.ServerScriptService.Libraries.Optimalization)
- oplib(outer)
- local weld = Instance.new("Weld")
- weld.Part0, weld.Part1 =
- torso, inner
- weld.Parent = inner
- weld = Instance.new("Weld")
- weld.Part0, weld.Part1 =
- torso, outer
- weld.Parent = outer
- local speedMulti = 0
- local finish = tick()
- if i == 1 then
- speedMulti = 2 * (myLevel*0.0025 + 0.25)
- finish += lifetime
- else
- speedMulti = 2 * (myLevel*0.0035 + 0.25)
- finish += postFirstLifetime
- end
- -- Speed and DMG
- local hit = false
- DamageMod:RegisterWeaponPart(args[1], {inner, outer}, damage, function() hit = true end)
- repeat
- hum.WalkSpeed = mySpeed.Value*speedMulti
- task.wait(0.05)
- until hit or tick()>=finish
- if hit then
- local finish2 = tick() + 0.3
- repeat
- hum.WalkSpeed = mySpeed.Value*speedMulti
- task.wait(0.05)
- until tick()>=finish or tick()>=finish2
- end
- inner:Destroy()
- outer:Destroy()
- task.wait(0.1)
- if i==hits or not hit then
- hum.WalkSpeed = mySpeed.Value*speedMulti/2
- break
- -- if not hit then hum.Sit = true end
- end
- end
- end
- return Use
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement