Jump to content
Sign in to follow this  
zulu1

Adding a second event handler

Recommended Posts

I did some searching, but I don't think I found the answer.

I'm using KMM International Solider which uses this event handler:

};

class EventHandlers {

Init="[_this select 0] exec ""\KMMint\scripts\init.sqs"";"

I want to equip them with Kyle Sarnick's grenades which also use an event hanlder:

class ECP_EventHandlers {};

class CfgVehicles

{

class All {};

class AllVehicles: All {};

class Land: AllVehicles {};

class Man: Land {};

class Soldier: Man {};

class SoldierWB: Soldier {};

class SoldierEB: Soldier {};

class SoldierGB: Soldier {};

class BD_GPSoldier: SoldierWB

{

vehicleClass="BDKS - Men";

displayName="Soldier (Grenade Pack)";

weapons[]={"M16","Beretta","put","BD_ThrowGP"};

magazines[]={"M16","M16","M16","M16","BD_M67","

BD_M67","BD_M67","BD_M67","BD_ANM83","BD_ANM83&amp

;quo

t;,"BerettaMag","BerettaMag","BerettaMag","BerettaMag&a

mp;q

uot;};

class Eventhandlers: ECP_EventHandlers

{

init = "_this call (ECP_resources select 40); [_this select 0,0] exec ""\bd_grenadepack\AddNewUnit.sqs"""

How can I merge the the two together to get the grenade to work properly?  I played around with {this add event hanlder} but maybe I had some syntax wrong. I appreceiate any ideas.

Thanks smile_o.gif

Share this post


Link to post
Share on other sites

Hi Zuku1,

Did you ever find out how to add a second eventhandler?

Thanks,

Benjamin

Share this post


Link to post
Share on other sites
Quote[/b] ]Did you ever find out how to add a second eventhandler?

No..you're the only one to reply.

Share this post


Link to post
Share on other sites

I hoped someone might have sent you a PM, as I'm also trying to find out how to add a second eventhandler.

Share this post


Link to post
Share on other sites

in the KMM eventhandler, just add

_this call (ECP_resources select 40); [_this select 0,0] exec ""\bd_grenadepack\AddNewUnit.sqs"" after the ;

so you should have:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">Init="[_this select 0] exec ""\KMMint\scripts\init.sqs"";_this call (ECP_resources select 40); [_this select 0,0] exec ""\bd_grenadepack\AddNewUnit.sqs"""

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×