Can A WeaponImage activate a cmd?

Author Topic: Can A WeaponImage activate a cmd?  (Read 1029 times)

Well, sorry about asking all these questions.. But how can you make it so, if a certain"<weaponname>Image pops up in some way, it activates a command?

What do you mean "pops up"?

It could mean you are either

1. Use the weapon

2. Activate the weaponimage with some function

Add a stateScript[0] = "onActivate" line to the state system and then use [weapon image]::onActivate(%this,%obj,%slot).

I'm sorry, but I tried what you told me, and it gave me a Buffer Overrun.

Maybe you missunderstand what I mean. I mean, Im trying to make it so, When I open a certain weapon, it goes 
Code: [Select]
messageClient(%client,'','\c1Blah Blah Blah');In other words, I would like it so that when I activate it It makes a message.
« Last Edit: June 26, 2008, 06:33:34 AM by BlockBrain »

Maybe you missunderstand what I mean. I mean, Im trying to make it so, When I open a certain weapon, it goes 
Code: [Select]
messageClient(%client,'','\c1Blah Blah Blah');In other words, I would like it so that when I activate it It makes a message.

You can use stateSequence
  • = "<script>"


Another way tho, is to use

Code: [Select]
function [b]<weaponImage>[/b]::onMount(%this, %obj, %slot)
Change <weaponImage> to your weapon image.

Oh yeah, I forgot about onMount.