Ok..... hi everyone once again. The last time I talked to you guys was on "Everon Siege" or whatever..... well that didnt quite work out and it is "in the closet" as I like to say. Now I am starting on a similar idea but it wont as difficult (I hope). The main idea is an RTS type game. Tons of objectives and squad customization
. So far so good except when it came to the whole "recruit a unit" part of the mission......
PROBLEM: ONCE THE NEW UNIT IS CREATED, IT WILL NOT JOIN YOUR SQUAD.
I tried both camCreate and createVehicle. Both did the exact same thing. Also tried a HELLAVA lot of different ways to make him join. No error messages come up but he just wont join my squad
Will keep trying it out but I dont think Im getting anywhere any time soon. PLEASE HELP.
[BEGINNING OF SCRIPT]
recruitXPos= getpos RecruitPos select 0; RecruitPos is a gameLogic
recruitYPos= getpos RecruitPos select 1
recruitZPos= getpos RecruitPos select 2
UnitType= lbCurSel 214
UnitTypeText = lbText [214, UnitType]
~0.5
;This part selects what kind of soldier will be created
? UnitTypeText == "Soldier" : goto "RECRUITASOLDIER"
? UnitTypeText == "Grenadier" : goto "RECRUITAGRENADIER"
? UnitTypeText == "Medic" : goto "RECRUITAMEDIC"
? UnitTypeText == "Machine-Gunner" : goto "RECRUITAMG"
? UnitTypeText == "LAW-Soldier" : goto "RECRUITALAW"
? UnitTypeText == "AT-Soldier" : goto "RECRUITAAT"
? UnitTypeText == "AA-Soldier" : goto "RECRUITAAA"
? UnitTypeText == "Black-Op" : goto "RECRUITABO"
? UnitTypeText == "Black-Op(Day)" : goto "RECRUITABOD"
? UnitTypeText == "Sniper" : goto "RECRUITASNIPER"
? UnitTypeText == "Engineer" : goto "RECRUITAENGINEER"
? UnitTypeText == "Crew" : goto "RECRUITACREW"
? UnitTypeText == "" : closeDialog 0; Close because of stupidity
#RECRUITASOLDIER
newGuy = "SoldierWB" camCreate [recruitXPos,recruitYPos,recruitZPos]
closeDialog 0
~1
units newGuy join (group Soldier1)
Exit
[END OF SCRIPT]
Soldier1 is me. I move to a tent and hit an action that activates a menu
. From this menu I select which kind of unit I want. Hitting recruit activates this script (I tested it with unit type and each one is created no problem. Just cant get him to be part of my squad). I only kept the first regular soldier because if he doesnt work, none of the others will. Anyone got any ideas on how to fix this? Or am I just being totally clueless