Hello, could really use a lil help with this
Got this great script working in my mp mission from Triggerhappy that executes a script on each players computers, in which it runs on a loop. The script checks if a player has lost rating in a town, thus the town hates him if he has.
Problem is a player could sit outside a town radius 'rating check area' and kill other players within that area, and the other player couldnt fire back without rating loss(all players are west), another words it a terrible opening for cheating.
So, I have added a simple trigger that uses "hit" eventhandler for any player, and of course a script. Only problems here are that I dont know the exact wording for finding if a player equals the _shooter, and also I dont know exactly what sort of a variable can be assigned to a player that I could reference in another script.
The first script is the temp script that I used to test if the essentials were working, second is the rough copy that prolly dont work, but it shows whats desired.
;A trigger event handler runs this script if any player "hit" within a proximity
;East side shooter is just temp test, shooter will be west
_shooter = _this select 1
_shot = _this select 0
?(_shooter == _shot): exit
?(Side _shooter == East):hint format ["Side _shooter == East"]
Exit
;Need to actually get if shooter equals a player. Then need to assign a variable(shooterplayer) to that player that can be referenced in another script that runs on each players computers that is looping. Below is desired script, but prolly written incorrectly.
_shooter = _this select 1
_shot = _this select 0
shooterplayer = objNull
?(_shooter == player):player = shooterplayer
Exit
Any help on the _shooter == player and the variable assigning to him would be great. Like I said, I need to reference that variable in another script which is running on each players computers. And the objNull part is there to remove any previous reference for shooterplayer so its only referencing one player at a time.
One last thing, I am using a Trigger to execute this with "hit", but I want to actually check the entire island for this occurrance, so the prox zone will be huge,-west present-, but only west in game will be players, would a zone that big cause lag?
TIA
Christian