Search the Community
Showing results for tags 'assignvehicle'.
Found 1 result
-
I am using the addaction menu to add quick on the fly troop management and vehicle assignment scripts. I have the troop management down solid. Units can come in and out of my group, and in and out of my high command module with the flick of the mouse wheel. However, the same cannot be said completely about assigning the vehicles. I got the assign part down, though I currently am not assigning drivers (yet). The problem is that when I choose to unassign one of my highcommand subordinates from their vehicle with my script, that vehicle is no longer eligible for reassignment or unassignment. My addaction for that car/tank/truck is just gone. Reactivating the script doesn't work. I can, however, reassign the group to another vehicle, however, if I unassign them, the same happens once again, vehicle is no longer eligible for reassignment. Just a note here, these groups were added under player with the "player hcSetGroup [group];". I do have a synced HCcommand module to my player, and a synced subordinate command module to the hc module on the map. addhcvehicle = { player addaction ["Assign to Squad 1", {mygrp1 addVehicle cursorTarget},nil,1,false,true,"",format ['(!(isnull cursortarget) && (alive cursortarget) && ({ alive _x } count units mygrp1 > 0) && ((side cursorTarget) == side player) && (locked cursortarget < 2) && !(cursorTarget isKindof "Man"))'],15,false]; }; null = []spawn addhcvehicle; removehcvehicle = { player addaction ["Remove from Squad 1", {mygrp1 leaveVehicle cursorTarget},nil,1,false,true,"",format ['(!(isnull cursortarget) && (alive cursortarget) && ({ alive _x } count units mygrp1 > 0) && (locked cursortarget < 2) && ({if (assignedVehicle _x == cursortarget) exitwith {true}}forEach units mygrp1))'],15,false]; }; null = []spawn removehcvehicle;
- 3 replies
-
- assignvehicle
- leavevehicle
-
(and 3 more)
Tagged with: