Merge pull request #124 from Ignatz-HeMan/patch-2

Random dir for static wpns
This commit is contained in:
Ghostrider [GRG] 2018-11-27 08:20:01 -05:00 committed by GitHub
commit 6ed84e53bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View File

@ -117,6 +117,7 @@ if (blck_debugLevel > 1) then
#endif #endif
_wep setVariable["GRG_vehType","emplaced"]; _wep setVariable["GRG_vehType","emplaced"];
_wep setdir (random 359);
_wep setPos _pos; _wep setPos _pos;
[_wep,false] call blck_fnc_configureMissionVehicle; [_wep,false] call blck_fnc_configureMissionVehicle;
_emplacedWeps pushback _wep; _emplacedWeps pushback _wep;

View File

@ -37,6 +37,7 @@ for "_i" from 1 to _statics do
_allBldPsn = _allBldPsn - [_pos]; _allBldPsn = _allBldPsn - [_pos];
_staticClassName = selectRandom _typesStatics; _staticClassName = selectRandom _typesStatics;
_obj = [_staticClassName, [0,0,0], true] call blck_fnc_spawnVehicle; _obj = [_staticClassName, [0,0,0], true] call blck_fnc_spawnVehicle;
_obj setdir (random 359);
_obj setVariable["GRG_vehType","emplaced"]; _obj setVariable["GRG_vehType","emplaced"];
_staticsSpawned pushBack _obj; _staticsSpawned pushBack _obj;
//diag_log format["_fnc_spawnGarrisonInsideBuilding_relPos: _obj = %1 | _staticsSpawned = %2",_obj,_staticsSpawned]; //diag_log format["_fnc_spawnGarrisonInsideBuilding_relPos: _obj = %1 | _staticsSpawned = %2",_obj,_staticsSpawned];