Ink. 10 Posted July 29, 2014 For example, I have Alpha 1-1 #, 1-2 #, etc etc. Is there anyway I can rename this so instead of Alpha 1-1 it could be X Squad or so? Share this post Link to post Share on other sites
L3TUC3 32 Posted July 29, 2014 For example, I have Alpha 1-1 #, 1-2 #, etc etc. Is there anyway I can rename this so instead of Alpha 1-1 it could be X Squad or so? Unfortunately, no. You can rename squads after the loading screen though. Share this post Link to post Share on other sites
Ink. 10 Posted July 29, 2014 Unfortunately, no. You can rename squads after the loading screen though. How so? May be a pain to have to do it each run but would be better than the alternative. Share this post Link to post Share on other sites
Grumpy Old Man 3545 Posted July 29, 2014 https://community.bistudio.com/wiki/setGroupId Only works after the mission started. Share this post Link to post Share on other sites
warlord554 2065 Posted July 29, 2014 So could you not just create a "squadnames.sqf" using setGroupId, and then call it from a trigger after mission start? Could save some time Share this post Link to post Share on other sites
CSLALUKI 30 Posted July 29, 2014 (edited) Yes, but the best way is to create a script file for example "LUKI_squadNames.sqf" and call it directly in init.sqf via execVM, no via trigger. Edited July 29, 2014 by [CSLA]LUKI typo Share this post Link to post Share on other sites
Ink. 10 Posted July 29, 2014 LUKI;2741998']Yes' date=' but the best way is to create a script file for example "LUKI_squadNames.sqf" and call it directly in init.sqf via execVM, no via trigger. That would be good actually. Got a link to a tutorial where I could do something like this? (I've never created a script file so I dunno where to begin) Share this post Link to post Share on other sites
CSLALUKI 30 Posted July 29, 2014 (edited) I create script for your squads ;). You must only name the units of each group as is in the "list of units in each group" in the script. ;) LUKI_gnch.sqf (this script set the group names for 4 groups created in map): /* Filename: Group name changer (GNCH) Author: LUKI How to run: Paste this into your init.sqf: [] execVM "LUKI_gnch.sqf"; Description: This script set the group names for your group directly if mission starts. */ //list of units in each group _g1 = [a1, a2, a3]; _g2 = [b1, b2, b3]; _g3 = [c1, c2, c3]; _g4 = [d1, d2, d3]; //name for each group _g1 setGroupId ["TF Squad"]; //set the name for squad 1 _g2 setGroupId ["Support squad"]; //set the name for squad 2 _g3 setGroupId ["Reconnaissance squad"]; //set the name for squad 3 _g4 setGroupId ["Paratroopers"]; //set the name for squad 4 Edited July 29, 2014 by [CSLA]LUKI Share this post Link to post Share on other sites
barbolani 198 Posted July 30, 2014 My super auto squad namer script. Assuming you are BLUFOR. [] execVM "squadnamer.sqf"; And the script: _count = 1; {_group = _x; _text= ""; if (side leader _group == WEST) then { //add classes depending on the type of vehicle, for example: if ((vehicle leader _group) isKindOf "Man") then {_text= "Inf"}; if ((vehicle leader _group) isKindOf "Tank") then {_text= "Armor"}; if ((vehicle leader _group) isKindOf "Truck") then {_text= "Mot"}; //etc etc.. you may use also typeOf if you want to speacialise Inf units, like paratroopers, recon etc... _text= format ["%1-%2",_text, _count]; _group setGroupId [_text]; _count = _count + 1; }; } forEach allGroups; This will name the groups like "Inf-1","Mot-2","Inf-3","Armor-4" etc.. Share this post Link to post Share on other sites
woods825 10 Posted July 30, 2014 I'm fairly new to scripting, but is it possible to sort of merge both of those scripts? I'm not familiar yet with a lot of the commands but being able to check the lead of the group's name, say I named him "leader_1", use something similar to barbaloni's script to check for just that one man then use something like LUKI's script to give each man's group a specific name so 2 different infantry groups could have custom names like "Hammer" and "Raven" Again I'm unfamiliar with the codes yet so here's the representation of what I'm trying to figure out: If group leader name is "leader_1" Then give group name "Hammer 1-Actual" If group leader name is "leader_2" then give group name "Hammer 1-1" If group leader name is "leader_3" then give group name "Hammer 1-2" If group leader name is "leader_4" then give group name "Raven 1-Actual" etc... Share this post Link to post Share on other sites
barbolani 198 Posted July 31, 2014 Woods, if you are using pure editor placed units, instead of any fancy scripting, put the names you want in the leader's init and keep things simple and customized for your mission. So just a pure: groupname = group this; groupname setGroupId ["whatevername"] is what you need. My method works for scripted spawned groups (well not exactly that, but with a few changes) where you created the groups with local script variables and externally to this, you don't know the rest of the group names, so you search for all the groups on any side and put them a name dynamically. No need of that in your situation. Share this post Link to post Share on other sites