[Bonus Plugin] Group Management System (GMS)

The place to discuss scripting and game modifications for X³: Reunion.

Moderators: Moderators for English X Forum, Scripting / Modding Moderators

User avatar
moggy2
Posts: 5505
Joined: Wed, 6. Nov 02, 20:31
x3ap

[Bonus Plugin] Group Management System (GMS)

Post by moggy2 » Wed, 13. Jun 07, 16:25

Name: Group Management System (GMS)
Version: 1.8
Date: 05.04.2007
Scripter: moggy2
  1. Commands Overview:
    1. . Setup Group
      • this command allows you to define the group
      • the ship you run this command on will be the group leader
      • you can set the name and number of the group,
      • entering nothing for the name will use the existing group name
      • you select the number, and type of ships to add to the group.
      • by default, ships added to the group will be given the command to protect the leader
      • ships will take the leader's homebase as their own
    2. . This Group: Attack Leader's Target
      • this command allows you to set some or all ships in the group to the command attack target of...leader
      • you can select how many ships should not be set to attack their leader's target
    3. . Group Management System
      • this command allows the ships to be have as group members
      • it makes sure the group stays together, by giving the order to protect the leader if this ship has nothing else to do.
      • it handles the automatic resupply of energy for jumpdrives, missile and ammo, when docked at stations that sell the supplies, or carriers that have the supplies.
    Setup Group command:

    The Setup Group command will ask for 4 options when it is run.

    The first option is the Fleet Name. This name will be given to all the ships in the group. You can enter various key words which are replaced by different values for each ship in the group, such as the fleet number and type of ship.

    The second option is the Group Number. This is used by other scripts to identify this group. There is nothing to stop you having 2 groups with the same number, in this case some scripts will affect both groups at the same time.

    The third option is the number of followers to assign to this ship. Entering 3 in this option would assign 3 other ships to follow the ship the command is run on, making 4 ships in the group all together.

    The fourth option is a class filter to allow you to select new followers from one particular class of ships, M5's, just fighters, etc. In most cases you can just select the class ship.


    setting the Group Name:

    When setting up the group, you can specify the name of the group. You can simply enter a name, in which case the group number, ship type and ship number will be appended to the name for each ship. You can however be more specific about what information is shown in the names of the ships in the group.

    The following keywords can be used in the group name:
    • %fnum This is the group number, specified in option 2 of the setup group command.
    • %shiptype This is an abrieviated version of the type of ship, eg P.Buster, Nova, etc.
    • %snum this is the ship's unique number within the group. Every ship is given a different number, to differentiate it from the others in the group.
    • %class this is the class of this ship
    • %sector this is the current sector the ship is in
    • %home this is the homebase of the ship
    The group name input can also take several options that make specifying the name easier:
    • - or a single space. Use the current group name. Useful if you just want to change the group number
    • -last or -l. Use the last entered group name. Useful if you want to have the same naming convention for several groups with just different group numbers
    • -default or -d. Use the default name pattern: Group(%fnum) %shiptype %snum
    • -unset or -u. This option disbands the group. The group parameters are removed from the ships in the group and the names are reset to their names before they became part of a group.
    • -unset1 or -u1. This removes just this ship from the group.
    • -null or -n. This is the same as -unset except that the ships names will be reverted to the game default for their class, ie. your buster



    Group Management System Command:

    The Group Management System Command is what performs the group maintenance such as refueling or restating ships to follow their leader. It is automatically started when you create the group with the Setup Group command, but can be shut down and restarted when ever necessary.

    If the leader of a group is killed in combat, another group member from the formation will take its place. However, if any group members run an other errand at the time, they will be orphaned and act like leaders from thereon.


    Other uses:

    The GMS is not limited to fighter groups. There are many other possible uses other than controlling combat groups. How about a group of TS's setup for Manual Trade Commands as a trade convoy, or a group of Discoverers with Fleet Support Ship software to deliver Jumpdrives to remote ships?


    Reasigning ships to new groups:

    When the Setup Group command is run not all the stored variables are reset. This allows existing groups to be updated without having all the exisiting ships settings reset. This can cause problems if you want to reassign a group ship to another group.

    Normal group ships can be reassigned with out too much problem. They will keep their default command from the previous group. A normal group ship with no command will be seen as 'free' by the Setup Group command

    Leaders of groups pose a slightly different problem. You can assign former leadships to a be members of a new group, but they will retain the default command of Attack all enemies rather than rejoining their group. The only way to remove their leadership tag is to 'unset' them from any group by running the Setup Group command using the -u or -u1 option. Group leaders are not seen as 'free' ships by the Setup Group command.

KaZsaru
Posts: 37
Joined: Sun, 10. Jun 07, 08:56

Post by KaZsaru » Thu, 14. Jun 07, 20:13

Wow, congrats on getting in the bonus pack! A question though:

I suspect the other "group" addons will not work with this version of GMS?

User avatar
moggy2
Posts: 5505
Joined: Wed, 6. Nov 02, 20:31
x3ap

Post by moggy2 » Thu, 14. Jun 07, 20:34

There's no reason why the unsigned plugins for GMS (missile management, carrier operation, etc...) won't work with this.

If you have GMS groups created with the unsigned version of GMS then you'll need to restart the GMS command in the ship's command menu. Quickest way to do that for the whole group is to rerun the setup command on the leader

matches
Posts: 202
Joined: Thu, 4. Jan 07, 22:47
x3

Post by matches » Thu, 14. Jun 07, 21:31

Thanks Moggy2! Sounds like a great configuration, can't wait to try it! :D
"Didn't your mother ever tell you not to play with matches?"



Realspace Backgrounds http://forum.egosoft.com/viewtopic.php?t=180848

KaZsaru
Posts: 37
Joined: Sun, 10. Jun 07, 08:56

Post by KaZsaru » Fri, 15. Jun 07, 02:10

any sign that the rest of the Group addons will get the signed tag?

User avatar
NUKLEAR-SLUG
Posts: 2372
Joined: Thu, 4. May 06, 13:20
x3tc

Post by NUKLEAR-SLUG » Fri, 15. Jun 07, 02:27

How is this essentially any different from just assigning a bunch of ships to protect a leadship?

User avatar
moggy2
Posts: 5505
Joined: Wed, 6. Nov 02, 20:31
x3ap

Post by moggy2 » Fri, 15. Jun 07, 02:50

NUKLEAR-SLUG wrote:How is this essentially any different from just assigning a bunch of ships to protect a leadship?
-restarting of default commands (attack all, or protect...(leader)) if a ship finds itself without a command
-self resupply of energy and md ammo, if needed.
-the ability for scripts to distiguish between groups

The setup group command makes assigning ships to a group easier.

other than that, a gms group is esentially the type of group you describe.

jlehtone
Posts: 21801
Joined: Sat, 23. Apr 05, 21:42
x4

Post by jlehtone » Fri, 15. Jun 07, 08:39

Moggy forgot the second general GMS command from the list: "Attack target of Leader". 50/50 split of escorts to 'Protect' and 'Attack target of ..' is much more efficient that all on 'Protect'. Yes, you can do that in vanilla too, but after setting up eight such groups by hand I said: "There must be an easier way!". GMS is. :D
Goner Pancake Protector X
Insanity included at no extra charge.
There is no Box. I am the sand.

googlemeier
Posts: 365
Joined: Mon, 28. Nov 05, 15:45
x3tc

Post by googlemeier » Fri, 15. Jun 07, 19:55

I have set up the leaders, groups and the following ships got their names accordingly.
But there are some ships left which can't take the GMS group command - it's simply not active.
I can assign them with protect leader x, which hasn't got ships anyway, but can take 5, but they don't belong to the group.

why are they different?

[Edit] solved the problem: fighters on protect x - restarted the GMS software on x with same parameters et violá...

Great_Daemon
Posts: 50
Joined: Mon, 11. Jun 07, 06:23
x3

Post by Great_Daemon » Tue, 19. Jun 07, 07:19

Could someone explain how to assign ships to groups - it doesn't say.

Thanks

jlehtone
Posts: 21801
Joined: Sat, 23. Apr 05, 21:42
x4

Re: [Bonus Plugin] Group Management System (GMS)

Post by jlehtone » Tue, 19. Jun 07, 08:54

You run 'Setup Group'.
* It will assign the ship you run it on as leader of the group
* It will assign all ships that already follow the leader as members of the group
* It will then look from non-active ships matching the filter for more members, up to number you specified.

Thus, either have only the ships you want to assign in the same environment, or have them already escort (ie protect/follow/...) the Group leader.


Minor observation actually unrelated to GMS. Multiple groups, all with BigShip leaders (M6) and Fighter escorts. Each group (leader) is told to jump to same sector (Jump-and-Fly-to-Station). BigShips queue for jumping, but Smallships do not. Smallships jump instantaneously, and then attempt regular flight to reach their leader, ie head for the first sector. This is a known defect of the stock formation jump logic. XaiCorp hosts a fix for the stock script, which makes the escorts wait until the leader has jumped, doesn't it?
Goner Pancake Protector X
Insanity included at no extra charge.
There is no Box. I am the sand.

Puruco
Posts: 527
Joined: Tue, 6. Dec 05, 00:09
x3

Post by Puruco » Tue, 19. Jun 07, 15:27

Hi moggy: If I want to have different name for each ship, not the same for the everyone, can I do that?

User avatar
moggy2
Posts: 5505
Joined: Wed, 6. Nov 02, 20:31
x3ap

Post by moggy2 » Tue, 19. Jun 07, 15:49

there's no way to tell setup not to change the names on each ship, or to use their old names in the group name pattern.

There's nothing stopping you changing their names afterwards though. That won't affect their ability to act like a group.

jlehtone
Posts: 21801
Joined: Sat, 23. Apr 05, 21:42
x4

Post by jlehtone » Tue, 19. Jun 07, 19:50

Besides, it is somewhat logical to have common part in the name of ships, which belong to the same Group. The Group is a unit. It fights together and dies together. :split:


I've now got all set up for the first combat test after the BP release. Four Groups, all number 6. In lack of imagination, the fleetnames are 'Blue', 'Cyan', 'Dora', and 'Emil'. Centaur lead and four Nova Vanguards in each, 50/50 Protect/Attack. Test target: XI. Will do single 'GHK Escorts Lauch Missile' (Typhoon) at each K, and then issue 'GHK Attack All Enemies'. Never tried that Combo before, so I have something to look for. :D
Goner Pancake Protector X
Insanity included at no extra charge.
There is no Box. I am the sand.

mrjabba
Posts: 46
Joined: Tue, 15. Aug 06, 15:48
x3

Post by mrjabba » Wed, 20. Jun 07, 20:25

I was a little unclear about how to assign other ships to the group, as well. The instructions do not make it clear that the ships you wish to add to the group must already be following the leader ship.

User avatar
moggy2
Posts: 5505
Joined: Wed, 6. Nov 02, 20:31
x3ap

Post by moggy2 » Wed, 20. Jun 07, 20:40

mrjabba wrote:I was a little unclear about how to assign other ships to the group, as well. The instructions do not make it clear that the ships you wish to add to the group must already be following the leader ship.
they don't have to be.

any ships in the same environment, ie flying in the same sector, or docked at the same station/carrier, that are not doing anything could possibly be added to the group when the setup command is run.
this is ideal for when you buy 10 new Nova's. You can create a new group from them with just one command.

When you run the setup command you specify the number of ships in the group. If you specify a greater number than you have ships currently following the leader, setup will attempt to make up the numbers from other ships in the area.

if you have a group of 4 busters docked at a carrier, and one more buster docked there as well. You can add that new buster to the group by simply running the setup command, specifying 4 or more (leader + 4 followers) as the number of ships to add to the group.

teladianium
Posts: 1331
Joined: Sun, 25. Sep 05, 13:49
x3

Post by teladianium » Thu, 21. Jun 07, 08:56

Hi, I think I scr**** up witn this command as my LX runs away when I eject and starts running the command "Attack All Enemies". I posted in technical support as I wasn't sure which forum to post in.


Here's my post:

I just took a trip to MooKye to collect a couple of ships, ejected from my LX, claimed a Falcon, hit delete to target the LX so I could press Shift+E to re-enter my ship and was shocked to see my LX 2 km away going at top speed.

I went into the sector map / ship / command console / none and it showed the LX slowing running command none then a second later the top left window of the hud showed it running command "attack all enemies". I did this a few times and each time it stopped for a second or so then changed back to "attack all enemies" and off it went.

I tried this using the sector map and by pressing return in space, targetting the LX and running command "none" - same deal.

I tried to tell it to follow me but it never got close enough for me to re-enter. Command Idle just set it off at about 70 m/s so that's no good.

I'm running a vanilla game 2.0.02 with bonus pack 3.1.06

After reloading I also tried undocking from a station and ejecting and same as above.

The only thing that I can think of is when I was doing a pirate base mission and one of my UTs was in the same sector, just released drones to jump out, so I thought, hey I'll use the "command all ships in sector, fighter drones, protect me" for a bit of help - that command seems to have disappeared, so I thought , okay I'll use the Group Command instead by tried pressing a few things, no idea what I'm doing, so gave up. But my ship name had changed to Leader or something so I just renamed it back to My LX (imaginative!). I've just read the readme for group commands but can't see anything there that says - disable all or whatever.

Can anyone help pls as I can't claim any ships now....


***************

I think I need to run the Group command again and do -unset ??

I noticed above that :
restarting of default commands (attack all, or protect...(leader))
if a ship finds itself without a command
this would seem to explain the LXs behaviour ?

Can't do much ATM as I'm at work and won't be home for 10 hours but if anyone can confirm this is the problem I'd be grateful....

cheers...

jlehtone
Posts: 21801
Joined: Sat, 23. Apr 05, 21:42
x4

Post by jlehtone » Thu, 21. Jun 07, 09:47

:lol:
Sorry, why didn't we thought about that before. :oops:

When a ship is part of a Group, it indeed has a "default command". For the leader it is "Attack all enemies". You know how akward it is to tell a ship attack a specific target knowing that when it succeeds in the kill, it will revert to 'None', even though there may be other enemies around. And on 'None' it will not react to attacks ...

Since you issued the 'Setup Group' on your ship, it automatically became the leader of the Group you created. GMS stays quiet while you fly the ship, but the moment you "transfer away", it takes control.

Unset group is the cure.

teladianium
Posts: 1331
Joined: Sun, 25. Sep 05, 13:49
x3

Post by teladianium » Thu, 21. Jun 07, 14:11

thanks jlehtone, I'll do that later....

User avatar
moggy2
Posts: 5505
Joined: Wed, 6. Nov 02, 20:31
x3ap

Post by moggy2 » Thu, 21. Jun 07, 18:53

you can also turn off the GMS command in the extra ships commands slot. This will stop the restarting of default commands, among other things, without destroying the group.

Post Reply

Return to “X³: Reunion - Scripts and Modding”