HELP! Sending info from server to client if client has ItemMap

fisk

New Member
Hello.

I have been using Wicked AI, and missions on my server for quite some time. Now I wanted to modify the script so that it only sends the player the announcement text IF and only if the player carries a radio.

One way of doing that is of course by using rSPAWN, but for some reason (in Epoch at least) I have been unable to use that. For some reason any code using rspawn have led to a pounding nothing (no client receives anything) regardless if I use an if-statement or not. Like this (this of course executed from the server):

[nil, nil, rSPAWN, "Some text", { hintSilent _this; }] call RE;
[nil, nil, rSPAWN, "if(true) then { hint 'asd';};", { call _this; }] call RE;
[nil, nil,rSPAWN, {if('ItemRadio' in (items player)) then {titleText ['Radio: Intel suggests the mayor of Chernogorsk has retreated to his mansion with a task force, guarding his supplies. Forwarding location.', 'PLAIN',10];};}] call RE;
[nil, nil,rSPAWN, "if(true) then {titleText ['Radio: Intel suggests the mayor of Chernogorsk has retreated to his mansion with a task force, guarding his supplies. Forwarding location.', 'PLAIN',10];};"] call RE;


One hypothesis I had was that rSPAWN is blocked by Epoch, but Epoch uses rSPAWN to announce kill-messages (X was killed by Y). Another hypothesis I had (and since my server has kill messages disabled) was that in doing so it blocks ALL kill messages.


So, now I am at a standstill, I am unable to accomplish my task which is for mission messages to appear only if the player has a radio. Please, halp!
 
I skipped doing it this way and resorted to add event handlers instead.

And it now works. :)
 
Fisk, could we discuss this in private if you don't want to post your work? I'd like to dev my missions along this line but also include audio.
 
Back
Top