Jump to content
Sign in to follow this  
swede

Making friends enemies.

Recommended Posts

HI!

Im doing a mission with swedish Un-soldiers placed in the "Res"-folder. I want them to be attacked by guerillas. But they are in the same folder(Res).......what can i do to make the enemies?

rock.gif

Share this post


Link to post
Share on other sites

Group them under an east soldier and make the soldiers probability of precense 0%. smile_o.gif

Share this post


Link to post
Share on other sites

If CreateUnit made units join the EAST group, will they be shot at too?

And probability of presence 0% - is that a typo?

Share this post


Link to post
Share on other sites

nope, 0% is right, that way they would be on east side but not have an east soldier as leader

Share this post


Link to post
Share on other sites

OK; I see the point, so what would happen if they *DID* have an East soldier as a leader?

Would they still be targetted?

I CreateUnit() civilian objects and attach them to an EAST leader (who is 100% presence) with join <East group name> yet they are not shot at by WEST. Any idea why?

Cheers,

Tracy

Share this post


Link to post
Share on other sites

BUGGER - DOUBLE POST :o(

OK; I see the point, so what would happen if they *DID* have an East soldier as a leader?

Would they still be targetted?

I CreateUnit() civilian objects and attach them to an EAST leader (who is 100% presence) with join <East group name> yet they are not shot at by WEST. Any idea why?

Cheers,

Tracy

Share this post


Link to post
Share on other sites

ok....thx i´m gonna try that and be back with the results!!

Share this post


Link to post
Share on other sites
BUGGER - DOUBLE POST :o(

OK; I see the point, so what would happen if they *DID* have an East soldier as a leader?

Would they still be targetted?

I CreateUnit() civilian objects and attach them to an EAST leader (who is 100% presence) with join <East group name> yet they are not shot at by WEST. Any idea why?

Cheers,

Tracy

Well, probably has something to do with the fact that they are not grouped with the east from the beginning.. smile_o.gif

And no, that 0% probability is not a typo.

Share this post


Link to post
Share on other sites

I do a very similar thing, group them with an east leader then put "deleteVehicle this" in the east unit's INIT so he gets deleted when the mission loads.

Share this post


Link to post
Share on other sites

Hi, thanks for your replies.

I have 20 East soldiers. Each soldier is leader of a group of civilian aggressors.

I have for each East soldier a public variable of type group:

Soldier #1: Agroup = group this;

Soldier #2: Bgroup = group this;

etc etc.

If I set probability of presence to 0% for each East soldier, and then:

"CIVILIAN" CreateUnit [pos, AGroup, etc etc.]

nothing happens. The civilian unit isn't created. Probably 'cos the group doesn't exist anymore smile_o.gif

I can't pre-create the civilian enemies at the start as Eizei suggested because the number of aggressors is dynamic. I don't fancy inserting 20 groups of 10 civilians each biggrin_o.gif

Any advice on how to dynamically associate CreateUnit made units with East (and have them targetted automatically by West)?

Again,

cheers

Share this post


Link to post
Share on other sites

Stick the east units on an island out of the way somewhere, stick the presence to 100%, and deletevehicle them when you run the script to create the civs.

See if that works. Horrible way to do it, but if the group is not being created properly then ..

Share this post


Link to post
Share on other sites

Another way and easiest way in my mind is to lay the soldiers down on the map, then save it. Open the sqm. file and look for the soldiers you want on the east side:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

class Item6

{

position[]={8901.852539,193.994995,7946.585938};

azimut=205.000000;

special="NONE";

id=47;

side="GUER";

vehicle="SoldierGCrew";

rank="CORPORAL";

skill=0.600000;

markers[]={};

};

Now this is a resistance soldier. Say if you wanted him east, you'd type east in GUER. Now those un soldiers, you want them east, you'd type east instead of guer. All clear?

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  

×