Jump to content
Sign in to follow this  
rimblock

settting group side and unit overriding the side ?.

Recommended Posts

Hi,

I am currently setting the side for a group and then assigning a unit to the group who may not belong to the groups side. This seems to be setting the unit to the unit (models) side and not the group side.

i.e.

_group = createGroup EAST;
_unit = _group createUnit ["I_G_medic_F", [9057.23,989.063,0], [], 0, "NONE"];

If I then use the debug console in the game and point at the unit and use the command "side cursorTarget;" I get GUER.

Is the unit designated side (for that model) overriding the applied side given when the group was created and if so any way to override ?. I would rather not have to change models for the unit just to move them to a different side.

Share this post


Link to post
Share on other sites

I think the model is inherently on whatever side it's supposed to be, but when assigning it to a group of another side it will be on that side (i.e. EAST = enemy), and the side command recommends when checking the side of a unit to refer to the unit's group, not the unit itself, to get more reliable results.

Share this post


Link to post
Share on other sites

Hi,

as I understand you want GUER group to be EAST? (in editor)You could put GUER group, EAST soldier with higher rank than leader of GUER group and probability of presence to 0 and group him with GUER group. In that case GUER group is EAST :)

Share this post


Link to post
Share on other sites
Hi,

I am currently setting the side for a group and then assigning a unit to the group who may not belong to the groups side. This seems to be setting the unit to the unit (models) side and not the group side.

i.e.

_group = createGroup EAST;
_unit = _group createUnit ["I_G_medic_F", [9057.23,989.063,0], [], 0, "NONE"];

If I then use the debug console in the game and point at the unit and use the command "side cursorTarget;" I get GUER.

Is the unit designated side (for that model) overriding the applied side given when the group was created and if so any way to override ?. I would rather not have to change models for the unit just to move them to a different side.

Make sure you force join your unit to the group as well. Don't ask me why...

[color="#FF8040"][color="#000000"]_group[/color] [color="#8B3E2F"][b]=[/b][/color] [color="#191970"][b]createGroup[/b][/color] [color="#000000"]east[/color][color="#8B3E2F"][b];[/b][/color] 
[color="#1874CD"]_unit[/color] [color="#8B3E2F"][b]=[/b][/color] [color="#000000"]_group[/color] [color="#191970"][b]createUnit[/b][/color] [color="#8B3E2F"][b][[/b][/color][color="#7A7A7A"]"I_G_medic_F"[/color][color="#8B3E2F"][b],[/b][/color] [color="#8B3E2F"][b][[/b][/color][color="#FF0000"]9057.23[/color][color="#8B3E2F"][b],[/b][/color][color="#FF0000"]989.063[/color][color="#8B3E2F"][b],[/b][/color][color="#FF0000"]0[/color][color="#8B3E2F"][b]][/b][/color][color="#8B3E2F"][b],[/b][/color] [color="#8B3E2F"][b][[/b][/color][color="#8B3E2F"][b]][/b][/color][color="#8B3E2F"][b],[/b][/color] [color="#FF0000"]0[/color][color="#8B3E2F"][b],[/b][/color] [color="#7A7A7A"]"NONE"[/color][color="#8B3E2F"][b]][/b][/color][color="#8B3E2F"][b];[/b][/color] 
[color="#8B3E2F"][b][[/b][/color][color="#1874CD"]_unit[/color][color="#8B3E2F"][b]][/b][/color] [color="#191970"][b]joinSilent[/b][/color] [color="#000000"]_group[/color][color="#8B3E2F"][b];[/b][/color][/color]

Made with KK's SQF to BBCode Converter

Share this post


Link to post
Share on other sites

Thanks for all the replies.

Ideally I would like to use any unit for any side. I would also like to be able to move any unit to any side at any time during the MP mission. This will be for player units so they can switch to different factions if they wish to.

The units seem to be locked to a particular side (probably in the configs) which makes it problematic in using them for other sides. Just wondering if anyone has found an easy way around this.

I do have a couple of ideas but rather than reinventing the wheel I was wondering if people had already found a working solution.

@jShock, the Side change is in order to inherit side relations which I believe is based on the units side rather than the groups side ?.

@FilaMOD, The units are the only units in the group so by default they are the highest ranked.

@KillzoneKid, Thanks, will add that in and see if it makes a difference.

Share this post


Link to post
Share on other sites

Ok, some progress,

Have sorted out the joinSilent (was using joinAsSilent) and it appears better with the units reporting the right side in the "side unit" check although for the two armed units, the crosshairs are red and for the Civ model (even though it is reporting WEST as the side, the crosshairs are grey...

Relations are set with;

Civilian setFriend [independent, 0];
Civilian setFriend [blufor, 1];
Civilian setFriend [Opfor, 1];

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  

×