A3Antistasi / antistasi-1.x

Antistasi Unofficial Community old version
http://a3antistasi.enjin.com/
39 stars 44 forks source link

safeDistance_recruit is hardcoded to 500 meters in ReinfPlayer #289

Closed MaxiARG closed 6 years ago

MaxiARG commented 6 years ago

https://github.com/A3Antistasi/antistasiofficial/tree/master/AntistasiOfficial.Altis/REINF -> reinfPlayer.sqf

Near line 12 reads this: if (((side _x == side_red) or (side _x == side_green)) and (_x distance player < 500) and (not(captive _x))) then {_chequeo = true};

In order for the Variable ' safeDistance_recruit' defined in "AltisData.sqf" and the others in the same forlder, to work, we need to remove the number 500. It should read:

if (((side _x == side_red) or (side _x == side_green)) and (_x distance player < safeDistance_recruit) and (not(captive _x))) then {_chequeo = true};

safeDistance_recruit limits the distance at wich you can spawn units in garrisons, if it reads 500 it wont take into consideration the mentioned variable.

In order to test the problem just set the variable to 1 meter in AltisData, start the game, teleport to the first garrison tower south of Kavala, take t he tower, and try to spawn units, it wont be posible. Replace 500 for the variable and it will work.

StefArma commented 6 years ago

Good point, probably an old merge of versions caused that, thanks a lot!