ID:267364
 
Is there something I can do to make it if a player is holding a button he charges up his sword then releases it for a spin attack?

--Ray
R.J.T wrote:
Is there something I can do to make it if a player is holding a button he charges up his sword then releases it for a spin attack?

Using the mouse procs might work for this. Currently there's no way to detect a key-down and key-up separately.

Lummox JR
In response to Lummox JR
Actually, it would be possible, but with a somewhat hacky method...
client
Center()
mob.Charge()

mob
var/action = ""
var/charge = 0
proc
actionloop()
if(!action)
if(charge)
icon_state = ""
ChargedAttack()
else
if(action == "Charge")
icon_state = "Charge"
action = ""
spawn(5) actionloop()
Charge()
if(!action)
action = "Charge"
charge++
ChargedAttack()
ohearers(src) << "[src] uses a charged attack!"
src << "You use a charged attack!"
for(var/mob/M in oview(src,1))
if(charge)
charge--
del(M)
In response to Garthor
Hey garthor, whats the ohearers proc?
In response to Drag0n
Everyone that can hear you.