celery 8 Posted August 30, 2007 I have tried to use createVehicle and createUnit to create a new man, but the selectPlayer command doesn't work on them. Is it even possible to switch into a unit created with a script? Share this post Link to post Share on other sites
HitmanFF 6 Posted August 30, 2007 I tried the following script, and it worked in MP on a dedicated server: test.sqs: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">@ (time > 1) hint format["%1", typeOf player] ~10 _newunit = group player createunit["SquadLeaderE", position player, [], 0, "FORM"] selectPlayer _newunit hint format["%1", typeOf player] ~10 _newunit = group player createunit["SoldierGNOG", position player, [], 0, "FORM"] selectPlayer _newunit hint format["%1", typeOf player] <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">[this] exec "test.sqs"in the init field of the initial unit. Share this post Link to post Share on other sites
Synide 0 Posted August 31, 2007 yeah, the created unit has to be 'local' to the computer where the unit you are issuing the 'selectPlayer' on lives... hence the above works 'cause the new unit is joining the players group... Share this post Link to post Share on other sites
celery 8 Posted August 31, 2007 It worked fine in singleplayer but not in multiplayer. Can it be made to work online? Share this post Link to post Share on other sites
celery 8 Posted September 1, 2007 When done online I assume the form of the new unit, but the old one still has my identity and so I don't get any more points for kills after switching. I tried to delete the old unit but with no success and it keeps respawning when he's killed. Share this post Link to post Share on other sites