Jump to content
Sign in to follow this  
Diealotus

Spawn a unit?

Recommended Posts

Please help me.

I need to spawn an enemy unit, but nothing seems to work for me. I have a marker called "here" and have tried the code

"soldierWB" createUnit [getMarkerPos "here", groupAlpha]

It doesn't seem to work. What am I doing wrong.

I have searched alot but this seems to be a very basic thing that everthing I find goes way over my head and alot about respawning.

Share this post


Link to post
Share on other sites

Have you tried a different class name. I might be wrong but I thought the class names were changed since OFP?

Edit - just checked, seems they are. Thats a suprise, they change half the commands but leave the class names the same.

Share this post


Link to post
Share on other sites

did you create that groupalpha or just copy it from the wiki......

try this and if it works the group is the problem

put a enemy unit in the area and name it suzie....make a trigger with this in activation and set it off some how.....

the unit should appear at your maker and then run to it's leader suzie or try and killl you

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">"soldierWB" createUnit [getMarkerPos "here", group suzie]

Share this post


Link to post
Share on other sites

thanks alot guys I have got it working it was a group problem biggrin_o.gif

Share this post


Link to post
Share on other sites

Sorry for being a pain

But now I have the spawn done how do I make the unit spawn in a tent or building. The tent is named spawntent and I have the building id but no idea how to do it.

Thanks for any help notworthy.gif

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×