Jump to content

Welcome to Gaming On Steroids Forums
Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more. This message will be removed once you have signed in.
Login to Account Create an Account
Photo

Stop channel canceling


  • Please log in to reply
2 replies to this topic

#1
Zwei

Zwei

    Advanced Member

  • Contributor
  • 2,201 posts
local t = {_G.MoveToXYZ, _G.AttackUnit, _G.CastSkillShot, _G.CastSkillShot2, _G.CastSkillShot3, _G.HoldPosition, _G.CastSpell, _G.CastTargetSpell}
function Block(state)
 if state then 
  _G.MoveToXYZ, _G.AttackUnit, _G.CastSkillShot, _G.CastSkillShot2, _G.CastSkillShot3, _G.HoldPosition, _G.CastSpell, _G.CastTargetSpell = function() end, function() end,function() end,function() end,function() end,function() end,function() end,function() end
 else
  _G.MoveToXYZ, _G.AttackUnit, _G.CastSkillShot, _G.CastSkillShot2, _G.CastSkillShot3, _G.HoldPosition, _G.CastSpell, _G.CastTargetSpell = t[1], t[2], t[3], t[4], t[5], t[6], t[7], t[8]
 end
end
 
To cancel all movement/spells call

Block(true)
to move again call

Block(false)
 
Ofc could be made more compact and might have some flaws but it could help some newer devs :)
 
Inspiration: Deftsu Challenger Stream

  • 0

#2
Deftsu

Deftsu

    donthackourgames

  • Ex-Core Dev
  • PipPipPip
  • 4,812 posts
that's why we have OnIssueOrder/OnSpellCast :fappa: atleast they trigger before the windup start for this reason, so you can block them
anyway, nice to see you learning some new stuff :P
  • 0

#3
Zwei

Zwei

    Advanced Member

  • Contributor
  • 2,201 posts

that's why we have OnIssueOrder/OnSpellCast :fappa: atleast they trigger before the windup start for this reason, so you can block them
anyway, nice to see you learning some new stuff :P

 

Haven't even thought about that :fappa:


  • 0




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users