[SCRIPT] PiloteAI III.70 (28.09.08)

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

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

jhondidfool
Posts: 197
Joined: Mon, 14. Aug 06, 14:20

Post by jhondidfool » Tue, 10. Jul 07, 21:13

the script is great! enemies are much toughter, but when AI pilots eject the ship goes on attacking me O_o, any chance that when they eject, the ship becomes salvageable (sp?) ?

User avatar
Azz
Posts: 1031
Joined: Tue, 18. May 04, 20:14
x4

Post by Azz » Wed, 11. Jul 07, 19:48

Thanks jhondidfool

But the script takes charge of the ejection of the pilots or AI only at the time of the destruction of the ship.
It does not take care of ship's capture...

The problem that you described must come from something else....
iou naud ouate, aille ama pis | Pilote IA | Site

jhondidfool
Posts: 197
Joined: Mon, 14. Aug 06, 14:20

Post by jhondidfool » Wed, 11. Jul 07, 20:07

only happend twice thought, most of the times it exploded, but a pirate elite went on firing :P

Lidza
Posts: 403
Joined: Wed, 12. Oct 05, 23:23
x3

Post by Lidza » Thu, 12. Jul 07, 20:54

jhondidfool wrote:the script is great! enemies are much toughter, but when AI pilots eject the ship goes on attacking me O_o, any chance that when they eject, the ship becomes salvageable (sp?) ?

Quite true

Once the pilot is ejected their ships often carry on as red to the player and it was in attack mode, carries on in attack mode until gets destroyed couple seconds later

looks to me a small glitch

Mailo
Posts: 1901
Joined: Wed, 5. May 04, 01:10
x3

Post by Mailo » Thu, 12. Jul 07, 21:04

Lidza wrote:Once the pilot is ejected their ships often carry on as red to the player and it was in attack mode, carries on in attack mode until gets destroyed couple seconds later

looks to me a small glitch
Yep, a bit annoying as I have a script to switch targets as soon as the old one is killed. This effect keeps me going after one ship a while longer.
Even worse, the ship is indestructable in that time, and managed to kill me by crashing sometimes.

User avatar
Azz
Posts: 1031
Joined: Tue, 18. May 04, 20:14
x4

Post by Azz » Thu, 12. Jul 07, 22:56

Strange
I've never seen that yet....

Maybe it is a latency between the moment when the ship is declared 'destroyed', (at this moment the script receives the signal and can creates a cosmonaut, or an escape pod for AI), and the moment when the graphic engine of the game start the explosion... And during this time the ship is in a hybrid state, declared disappeared, but not destroyed physically.... :gruebel:

Can you tell me if you are running a mod so that I could orient a little my researchs?
iou naud ouate, aille ama pis | Pilote IA | Site

Mailo
Posts: 1901
Joined: Wed, 5. May 04, 01:10
x3

Post by Mailo » Thu, 12. Jul 07, 23:10

I'm running XTM with most of the DDRS-ships installed. The latter are not the reason though, the delay was the same before I installed them.
I found though the ship does not attack anymore, it just sits there at speed 0 for 1-2 seconds.

wanderer
Posts: 278
Joined: Wed, 6. Nov 02, 20:31
x3tc

re.: some improvements

Post by wanderer » Fri, 13. Jul 07, 10:39

Hey Azz,


very cool script, I used the Leveling AI (with a little recoded by myself) and it worked good. But your's rock's it out....

Even its without command conflicts with the big packages (XTM, Bonus, X3plus) - whow and it seems really good testet. My thanks, not seen very often...



Still, here some bug/improvment-request points:

- T-file 497161 is empty after installation with script installer (german installation) - well not a great problem, I copied the english and change it to german.

- above t-file error leads to a station naming error for the Hacker Bases -> 'ReadText7161-90'. I changed the t-file, so its now correct. But still get this station name. So I made a small 'rename' script, and set the name by hand. The stations only spawns on the first start of the script, so the will not be renamed anymore.

- patch and bonus folder not deployed when installing with script installer - its also no big problem. I used them from your zip-file.

- :wink: a well, an AI for a Mine and maybe a sat or station??? - I have one for a minefield - cool isn't it? No real influence onto the game as I see.

- Script 'Leveling AI' is incompatible, while this script is also using 'signal_killed' and it changed the original '!plugin.acp.fight.skill.std.pck'. So, users who installed it have to rollback the original *.pck's.
Still, seems the through this script set 'tactical' (in engl. fightskill) values will be used by your's. But you are not setting the rank after this fightskills. I got some pilots with skills 26 and rank Able.
Seems you only checked the Uni traders for ranking on first start, not other ships. Also, after one of this ships now kills an enemy, its reseted to rank Able and Skill. So you didn't recognise in your scripts, that there may be some skill levels before you start your AI. Would be fine, if you could check all ships first before starting, and assign the proper values.

- Skills and ranks: You set the rank for Uni.traders corresponding to their actuall value when the script is started first time -> correct?. Now, some of this are now rank 25, feels good, but not very real, while the skill levels for fighting ships will be harder to achive. Idea: Could you wage them somehow?

- Well you made a hell of a PDF doc, but please can you include a list with the 'short names' you are using inside the game log or messages e.g. 'Cptce', CamK3, ... .

- Question: Possible to integrate into the CIAD? (http://forum.egosoft.com/viewtopic.php?t=173007).
This would be great, so players can show inside the game for help, no task switcher or printout needed.

- Renaming option ship: An overview of the possibilities would be good (Chapter 10 is 'very' empty :wink: )

- Renaming option AI name: Possible to set a variable during renaming to show the skill and/or rank? As above, an overview of the possibilities would be good.

- XTM compatibility. Its working, but some minor adjustments maybe (?). The M8 class will be selected by the 'Rename ship' as an M1. Nop, can change it by hand. But does it have influence onto your group system or leveling system. Same questions goes about the M0 classes.


For info; used enviroment:
EGO Bala Gi + XTM 0.7.2 + Bonus 3.1.06 + X3Plus Pack 3.2.03 (http://forum.egosoft.com/viewtopic.php? ... highlight=, in german, sorry) + several scripts.
No Command conflicts!
Script installer 1.86


Do you need a german tanslations for the t-files?


By the way, I found the idea about the pirate pilots ejecting great. This may 'leed' to BBS stories to capture pirates, rescue passengers, or so, ...if implemented :-) ...


regards

User avatar
ttl
Posts: 537
Joined: Sun, 6. Feb 05, 13:04
x3tc

Post by ttl » Fri, 13. Jul 07, 12:50

I'd like to take some of the slot usage points up here, since there's no point in crowding up the library sticky. My reason is that this sounds interesting, but I won't use a script that not only hogs, but quite clearly wastes so many commands slots.

The point with the slots being that a lot (if not most) of the slots are apparently used for install/uninstall/setup kind of things. All these can be replaced by a single command that takes argument(s) for which of these operations to run. For example the four(!) rename commands can surely be replaced by one that first asks a number 1..4 or a string 'sect'/'base'/'squad'/'this', and then runs the corresponding command.

Sure you need more of a manual to use it that way (and descriptive comments for the arguments), but I for one would never consider using a script that takes that many slots. A menu structure is an alternative if you want to be more fancy. See Anarkis Carrier Commands or the Commercial Agent for examples. People of your caliber in scripting ability can surely handle these slot issues if you just put your mind to it. So please have some consideration for other scripters.

User avatar
Azz
Posts: 1031
Joined: Tue, 18. May 04, 20:14
x4

Post by Azz » Fri, 13. Jul 07, 21:44

Hello ttl


Thank you for the advice :)



A few remarks anyway:
A menu structure is an alternative if you want to be more fancy. See Anarkis Carrier Commands or the Commercial Agent for examples.
many functions are already in 'internal' menu to limit the number of slots :

[ external image ]

[ external image ]

[ external image ]
For example the four(!) rename commands can surely be replaced by one that first asks a number 1..4 or a string 'sect'/'base'/'squad'/'this', and then runs the corresponding command.
some functions depend on a selection of the player (select A sectors where are the ships to rename, select A class of ships to rename, select A station etc) because of the very elementary system of input (you know, you must input all the selections before the script will be started), these functions can't be simply merged in one, although there are libraries which could allow it (mEngine Interface by Prizz), but that becomes quickly very complicated and my purpose in the life is not only scripting.
(but to temperate that, may be I will look on the use of this library during my vacation, the rainy days...)
I won't use a script that not only hogs, but quite clearly wastes so many commands slots.
It's ok for me, if you don't like it, don't install it, nobody is obliged ;)


To be more constructive, if you want you can help to rewrite these functions and merge them at your liking, I shall be very happy to cooperate and to integrate them into the script.




wanderer :
I used the Leveling AI (with a little recoded by myself) and it worked good. But your's rock's it out...
- Script 'Leveling AI' is incompatible, while this script is also using 'signal_killed' and it changed the original '!plugin.acp.fight.skill.std.pck'. So, users who installed it have to rollback the original *.pck's.
Nemeo wrote Leveling AI being inspired by pilotAI, in a more liter version and according to his taste. You maybe noted that he uses the same text file that PilotAI (7161) to be sure that people dont install the two scripts. :)
- T-file 497161 is empty after installation with script installer (german installation) - well not a great problem, I copied the english and change it to german.

- above t-file error leads to a station naming error for the Hacker Bases -> 'ReadText7161-90'. I changed the t-file, so its now correct. But still get this station name. So I made a small 'rename' script, and set the name by hand. The stations only spawns on the first start of the script, so the will not be renamed anymore.
Yes, if the t-files 497161 was empty, the station were created withe a name like 'readtext error....', that would have caused problems then, because the script uses the name of the station to know that it is hacker's station...
I will make it less dependent on the name to avoid this kind of mistake (e.g move from an English version of the script to a German version)
- patch and bonus folder not deployed when installing with script installer - its also no big problem. I used them from your zip-file.

It is voluntary, to oblige people to make the manipulation in full knowledge of the facts (do not replace files without warning them)
With the spk version, these files are in the '/extras/pilote AI III' folder, it's writed in the doc ;)

I got some pilots with skills 26 and rank Able.
By default, the system of attribution of a random fihtskill in the creation of the vessel is kept, the fightskill and the rank are thus disconnected, but progress then together.
You can so have a naturally very bright pilot in fight (hight fightskill) but not still very graded.
The fightskill and the rank will increase then together according to the victories, the fightskill giving advantages in fight, and the rank bonuses of speed / sterring and access to more evolved functions...

But if you prefer you can use the parameter 'Fighting skill set at 1 when starting' in the X3 AI menu, so that
every ship bought or captured will have fighting skills initially set to 1 instead of being set at random.
Seems you only checked the Uni traders for ranking on first start, not other ships. Also, after one of this ships now kills an enemy, its reseted to rank Able and Skill. So you didn't recognise in your scripts, that there may be some skill levels before you start your AI. Would be fine, if you could check all ships first before starting, and assign the proper values.
yes it's true, I had not thought that somebody could use the script of nemeo and then change to pilotAI (no offense, it is just that the script of nemeo is not very known on the French forum)
I would have to look which variable he uses to store the rank and make a small conversion (he uses only 8 ranks against 30 for pilotAI)
- Skills and ranks: You set the rank for Uni.traders corresponding to their actuall value when the script is started first time -> correct?. Now, some of this are now rank 25, feels good, but not very real, while the skill levels for fighting ships will be harder to achive. Idea: Could you wage them somehow?
Yes good idea
- Question: Possible to integrate into the CIAD? (http://forum.egosoft.com/viewtopic.php?t=173007).
This would be great, so players can show inside the game for help, no task switcher or printout needed.
I did not completely manage to understand what do this script (my English is not always very good, and my German even less)
- Renaming option AI name: Possible to set a variable during renaming to show the skill and/or rank? As above, an overview of the possibilities would be good.
not yet possible but good idea, i'll take a look to this kind of function.

- XTM compatibility. Its working, but some minor adjustments maybe (?). The M8 class will be selected by the 'Rename ship' as an M1. Nop, can change it by hand. But does it have influence onto your group system or leveling system. Same questions goes about the M0 classes.
I am afraid of not being able to make much. I think that they attributed the class ' M1 ' to certain ' M7 ' to allow them the docking of ships above m3 (or more than 2) (but I did not verify)
Do you need a german tanslations for the t-files?
yes indeed, if you are interested, just PM me :)

a+
iou naud ouate, aille ama pis | Pilote IA | Site

Kilrathi Avenger
Posts: 275
Joined: Fri, 6. Feb 04, 20:16
x3tc

Suggestion addon

Post by Kilrathi Avenger » Fri, 13. Jul 07, 21:56

It would be nice if pilots could gain medals ala Terracorp for certain milestone i.e.

Fighter.

Bronze Star surviving for 1 game years, +1 Engine tuning for experience
Silver Star surviving for 2 game years
etc

Trader .

Peddellers medal 1st million profit, +1 engine tuning
Storekeeper medal 2nd million profit,
etc

When i enter any of the hacker stations my ship suffers a major explosion on departure, is it possible to stop this as it is very expensive to pay on the BBS every time and as it now costs 200k each time it is not worth me entering these stations, to sell a few 10k pilots. Help please.
"As I slide down the banister of life;
my job is just another splinter in the bum"

Mailo
Posts: 1901
Joined: Wed, 5. May 04, 01:10
x3

Post by Mailo » Fri, 13. Jul 07, 22:28

CIAD is basically an ingame manual for scripts. That way you don't have to alt-tab outside of the game to find out what a command does. It probably will be a lot of work though to type all the needed text for this.

Also, I second the request to put an explanation of abbreviations into the manual ... I still don't know what Cptce is ;)

If you have the time to work on the script some more, the ejected pirates part could do with some more fleshing out. I've pretty much given up collecting them as I still fly around in an M3, and returning to a base every 5 pirates killed to collect 30k credits is not very effective.
Or is there a command for a ship to collect all pirates in a sector? That would be a good use of an TP.

Kilrathi Avenger
Posts: 275
Joined: Fri, 6. Feb 04, 20:16
x3tc

Post by Kilrathi Avenger » Fri, 13. Jul 07, 22:42

Mailo wrote: a command for a ship to collect all pirates in a sector? That would be a good use of an TP.
Brilliant idea mate :)

Would finally give a useful purpose to the TP.
"As I slide down the banister of life;
my job is just another splinter in the bum"

User avatar
Azz
Posts: 1031
Joined: Tue, 18. May 04, 20:14
x4

Post by Azz » Fri, 13. Jul 07, 23:07

Kilrathi Avenger :

Good idea, i write down
(ok, ok I will spend ALL my holidays to script :cry: )
But engine tuning and steering are already earned when the pilot goes up in rank.

When i enter any of the hacker stations my ship suffers a major explosion on departure, is it possible to stop this as it is very expensive to pay on the BBS every time and as it now costs 200k each time it is not worth me entering these stations, to sell a few 10k pilots. Help please.
Sorry, thats is not due to the script ;)
Anyway you can sell the pilots in any pirate station, not only to hackers... (or if you are a hero, drop them in a regular station and content you of thanks and reputation;)

Mailo :
cptce = competence = fightskill

Or is there a command for a ship to collect all pirates in a sector? That would be a good use of an TP.
you can already command a TP to do that, but one by one

ok I also note it ... :)
iou naud ouate, aille ama pis | Pilote IA | Site

Mailo
Posts: 1901
Joined: Wed, 5. May 04, 01:10
x3

Post by Mailo » Sat, 14. Jul 07, 01:51

Azz wrote: (ok, ok I will spend ALL my holidays to script :cry: )
Please do not script just because you feel you have to. That way you'll get sick of it and either quit or do a worse job than you could if you had fun doing it.
The script is already great the way it is now, improvements are of course always welcome but not required :)

Lidza
Posts: 403
Joined: Wed, 12. Oct 05, 23:23
x3

Post by Lidza » Sat, 14. Jul 07, 10:21

Azz wrote:Strange
I've never seen that yet....

Maybe it is a latency between the moment when the ship is declared 'destroyed', (at this moment the script receives the signal and can creates a cosmonaut, or an escape pod for AI), and the moment when the graphic engine of the game start the explosion... And during this time the ship is in a hybrid state, declared disappeared, but not destroyed physically.... :gruebel:

Can you tell me if you are running a mod so that I could orient a little my researchs?

I'm running X3 latest version + XTM latest version and scripts installed are:

Anarkis carrier commands
explore sofware
Nividium mines
PiloteIAIII
Race Response Fleets
Satellite Limited Trader
X0ne Turret control system
Xtended Mod Scripts

I hope this helps :)

I have to say I like very much your script and that small glitch isn't a show stopper for me.

I found last night other situation this time with fighters in a squadron. In a squadron of 2 ships, one break fighting and remained static in space while the other carried on the attack. I had to order the squadron to dock and reissue 2nd attack order to make it resume the attack. I'll get back on this one if this happens again.

BTW in case of pilot ejecting, would be possible to (randomly) leave their ships for cap instead of getting them destroyed in the process? That will be brilliant.

Thanks

User avatar
Azz
Posts: 1031
Joined: Tue, 18. May 04, 20:14
x4

Post by Azz » Sat, 14. Jul 07, 12:15

Mailo :

Thank, but don't worry, I was just joking :)
As soon as the sun shines, I will go in my garden, or ride my bicycle..

Simply I like this way of making progress the script. I note the ideas of the users and when I feel like to do that, I spend some evenings in scripting.
Many functions of the script came from ideas or from suggestions of persons on the French forum.

Lidza :
I'm running X3 latest version + XTM latest version and scripts installed are:

Anarkis carrier commands
explore sofware
Nividium mines
PiloteIAIII
Race Response Fleets
Satellite Limited Trader
X0ne Turret control system
Xtended Mod Scripts
perhaps race response fleets..

I will have a look at this problem, but i must say that i've not yet understood very well the glitch that you describe



I found last night other situation this time with fighters in a squadron. In a squadron of 2 ships, one break fighting and remained static in space while the other carried on the attack. I had to order the squadron to dock and reissue 2nd attack order to make it resume the attack. I'll get back on this one if this happens again.
It seems that you gave an order to this ship without realize.
The most frequent error is for example to ask for the status of a ship. This one interrupts its current order (here ' follow and protect your leader ') to execute the new one ('display status') and then stay in space, waiting for another new command.

To avoid that you must execute the command from the menu of your own ship.

There is two way to proceed :
- If your are in the same sector, you can target the ship, and then ask for its status from your menu
- You can unselect any target, and then bring the command of status from your menu, the script will ask you then to choose the ship to be shown.

when this kind of mistake happens, just gives a squadron order to the group and it will re-form automatically (ex. 'SQ-Attack All' or even 'SQ-stop')
iou naud ouate, aille ama pis | Pilote IA | Site

User avatar
ezra-r
Posts: 3420
Joined: Fri, 14. Oct 05, 21:04
x4

Post by ezra-r » Sun, 15. Jul 07, 14:11

IS this incompatible with Bail Signal Extension? http://forum.egosoft.com/viewtopic.php?t=181131

User avatar
Azz
Posts: 1031
Joined: Tue, 18. May 04, 20:14
x4

Post by Azz » Sun, 15. Jul 07, 19:40

Hello ezra-r

I looked in the script and everything seems OK.
Voxol had the good idea to send a Signal-Killed for the abandoned ship, this guarantees that the squadron will be reformed if it's a player's ship.
On the other hand it can involve a small glitch :
When a ship is abandoned, the script of Voxol is going to create an astronaut, then PilotAI gets the Signal-Killed and thus creates one astronaut or one AI rescue pod (randomly according to the race).
We can thus have in some cases two ejected pilots, or one pilot and one AI.
But nothing prevents that a ship embarks several pilots, co-pilot and AI-co-pilot (remember R2-D2 ;))

Finally PilotAI will also calculate a bounty and a experience bonus if it is a ship of the player wich managed the capture.

So the cohabitation of these two scripts should cause a lot of interesting things :)
iou naud ouate, aille ama pis | Pilote IA | Site

Mailo
Posts: 1901
Joined: Wed, 5. May 04, 01:10
x3

Post by Mailo » Sun, 15. Jul 07, 22:05

Azz wrote:I would have to look which variable he uses to store the rank and make a small conversion (he uses only 8 ranks against 30 for pilotAI)
I have an AI which is level 65 with Exp 54 after 419 ship kills. Rather nice, the speed and manoever boni are 8 and 4.

I switched the levelling AI in the player ship on which resulted in the above, this nicely replaces the need for Cycrow's Overtuning, as you have to work for it and not just fork over cash.

I still wonder if this was intended ;)

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