sgtelis 11 Posted October 7, 2016 So from what I've been able to figure out the code "player allowDamage true;" only gets done on the client that it's called on. In my mission I'm making this turns out really strange.In the begining everyone are unkillable (using allowDamage false) and then when the mission actually starts I want them to take damage. However, due to it not being called properly the players can kill themselves with grenades but not kill eachother. Share this post Link to post Share on other sites
Bnae 1431 Posted October 7, 2016 Depends how you're calling the code Share this post Link to post Share on other sites
sgtelis 11 Posted October 7, 2016 I call it through a script, more than that I don't know how to do. Share this post Link to post Share on other sites
cuel 25 Posted October 7, 2016 https://community.bistudio.com/wiki/allowDamage Note the "AL" icon, The thing you're executing it on has to be local, in your example you're using player, which is the current "player" object on each client. Player object is always local (for each client, on a dedicated it does not exist - objNull). Note the "EG" icon, that means that it's broadcasted, so no, you would not have to execute it on every machine. You should post the script and how it's called 1 Share this post Link to post Share on other sites
Bnae 1431 Posted October 7, 2016 What i ment is, please could you post the code here so i can tell are you calling it in the right way > global or local > on every machine or only server Share this post Link to post Share on other sites
sgtelis 11 Posted October 7, 2016 Well, it's presented right in the link you sent. player allowDamage true; called in a script I call from the init.sqf This makes that player only able to kill him self and not other players. Share this post Link to post Share on other sites
sgtelis 11 Posted October 8, 2016 Ok, to clarify even more. This is taken directly from that link too: Multiplayer: This command only works locally and must be run on all machines to have global affect. How do I run it on all machines? Works locally since I can kill my self but for everyone else I still dont take damage. Share this post Link to post Share on other sites
davidoss 552 Posted October 8, 2016 in initPlayerLocal.sqf //executed by every player connected [] spawn { waitUntil {sleep 1; !isNull player};// waiting for player spawn and become global for every others player allowDamage false; }; Share this post Link to post Share on other sites
sgtelis 11 Posted October 8, 2016 in initPlayerLocal.sqf //executed by every player connected [] spawn { waitUntil {sleep 1; !isNull player};// waiting for player spawn and become global for every others player allowDamage false; }; well, yeah. I got that far. The problem is making them take damage again. Share this post Link to post Share on other sites
sgtelis 11 Posted October 8, 2016 Got it working, problem was (I think) that I changed it to false and then to true in different scripts. Not sure though, but it works now. Share this post Link to post Share on other sites