Jump to content
Sign in to follow this  
bedlam

whats wrong here.. EH "fired"

Recommended Posts

class eventhandlers

{

Fired ="if  ((_this select 4)=={B_LAW}) then {(_this select 0) removeweapon {B_LAWLauncher}}";

};

// B_LAW= projectile

// B_LAWLauncher=weapon

its causing CTD

Share this post


Link to post
Share on other sites
class eventhandlers

{

Fired ="if  ((_this select 4)=={B_LAW})    then {(_this select 0) removeweapon {B_LAWLauncher}}";

};

//   B_LAW= projectile

//   B_LAWLauncher=weapon

its causing CTD

Try:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">Fired ="if  ((_this select 4) == ""B_LAW"")  then (_this select 0) removeweapon ""B_LAWLauncher""; ";

instead.

Share this post


Link to post
Share on other sites

Fired ="if ((_this select 4) == ""B_LAW"") then (_this select 0) removeweapon# error type object expected array.... it says

Share this post


Link to post
Share on other sites

Well, at least it's not CTD'ing  smile_o.gif

Not sure what the problem is. Try:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">fired =  "hint format[""%1, %2, %3, %4, %5"", _this select 0, _this select 1, _this select 2, _this select 3, _this select 4];"

And make sure that (_this select 4) is what it's supposed to

be.

Share this post


Link to post
Share on other sites

WEST Alpha Black:1

(Bedlam), B_LAWLauncher,

B_LAWLauncher, B_LAW,

B_LAW

Share this post


Link to post
Share on other sites

Err, what about:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

Fired ="if  ((_this select 4) == ""B_LAW"")  then {(_this select 0) removeweapon ""B_LAWLauncher"" } ";

We're getting closer, I think wink_o.gif

Share this post


Link to post
Share on other sites

it works if i remove another weapon on this person.

is it because the lawlauncher is active that causes ctd?

Share this post


Link to post
Share on other sites

Maybe. Could you remove the ammo instead? Or try selecting

the 'other' weapon, then removing the LAW?

You can get list of the weapons the soldier is carrying

using the 'weapons' command.

Share this post


Link to post
Share on other sites

hmm doesnt work with original lawlauncher either.

must be a EH "fired" code fault or something.

Share this post


Link to post
Share on other sites

looks like u cant delete a active weapon instantly as the EH will do.. some pause is needed.. fixed it with a script instead.

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  

×