[Discussion] Generic X3TC S&M questions II

The place to discuss scripting and game modifications for X³: Terran Conflict and X³: Albion Prelude.

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

gopl
Posts: 31
Joined: Sun, 8. Mar 09, 01:46
x3tc

[SCR] AzzPiloteIA ???

Post by gopl »

Hello
Y is there a script on X3TC Articles by genre
AzzPiloteIA X3 Reunion?

Thank you
User avatar
LV
Sith Lord
Posts: 8255
Joined: Wed, 6. Nov 02, 20:31
x3tc

Post by LV »

As far as i can see there isn't, link??

merging into general questions
User avatar
Serial Kicked
Posts: 3823
Joined: Fri, 12. Aug 05, 20:46
x3tc

Post by Serial Kicked »

I don't think there is.

It was a script for Reunion that was improving the fightskill of player ships and NPC ships over time (well, after each kill). It also included basic wing management, similar to what's is now included in TC (in less buggy).

He already asked in the french board. I was about to answer him.
X3:TC/AP Pirate Guild 3 - Yaki Armada 2 - Anarkis Defense System

Anarkis Gaming HQ
Independent Game Development
X3 Scripting and Modding Station
mark_a_condren
Posts: 1468
Joined: Wed, 3. Aug 05, 05:05
x3tc

Post by mark_a_condren »

What kind of Animation is the Landing bay doors?

I've read numerious times that there are 2 kinds of animation in the game.
1) Constant, like radar dishes and rotating station parts.
2) Turrets, Pitch and Yaw for tracking targets.

I get those 2 no probs, but my poor fuzzy old brain can't for the life of me work out which of these 2 landing bay doors fits into, as they fit neither of these movement types. They open, stop and let ship in / out, then close and stop, wait for next ship, rince and repeat.

Any answers i would be grateful for.

MarCon
Dant12
Posts: 22
Joined: Tue, 18. Nov 08, 00:16

HQ speed

Post by Dant12 »

how can I make the PHQ build/research faster? for the amount of time I have available to play, it takes too long to build stuff :(
I don't want it instant, a 40% speed up would do enough wonders
User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Post by Gazz »

Mod their average price? AFAIK that number controls building speed / resources.
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.
Dant12
Posts: 22
Joined: Tue, 18. Nov 08, 00:16

Post by Dant12 »

Cool, that worked
Kadatherion
Posts: 1021
Joined: Fri, 25. Nov 05, 16:05
x4

Post by Kadatherion »

Searched around a bit but couldn't find any direct infos, so:

I'm messing around a bit with my Jobs file to add some custom ships in the universe, and no issues on that matter. While I was there, I took the chance to reduce the max number of running jobs for civilians by a fair share (around 75%, or even more like for those ridiculous 700 max jobs unnamed civs). I know this has always been an harmless way of improving performance since Reunion, however I noticed two things that make me wonder...

- Civilian jobs are flagged as "Destroy Out of Sector" in the placement tab. If that does what looks like, it would seem rather pointless to reduce 'em, since they would anyway not being called apart from those few active IS where you are. Or it actually isn't exactly what looks like? :P

- They also seem to run either one of these three commands: add.wares.one.one, add.wares.few.one or add.wares.much.one. All are with function local.stationtostation (which seems natural since they shouldn't exist OOS and as such they don't even fly from one sector to another), with the exception of taxis which have a special dedicated function.
That add.wares made me wonder... do they actually TRADE or anyway transfer wares between stations in sector when they are active? As such they do in the end have an even slight use that, by disabling or heavily reducing 'em, could have noticeable repercussions in the long run?
SoniG
Posts: 14
Joined: Sat, 21. Feb 09, 17:31

Post by SoniG »

I have been searching quite a bit but not much luck, what I have been experiencing is, that whatever changes I do in my globals.txt file, it doesnt appear in game. As I am no novice in X3 moding (successful merge of Imp's cockpits with Xtra shippack and ColourEngine) it kinda hits me.

I have tried to put it in my merged mod types directory, into X3TC/Types folder and even tried to make changes to the original Globals.txt file, but not luck. False patching tried also.

There might be a simple mistake im doing over and over but I just tend to not spot it.

Thank you for replies
User avatar
Serial Kicked
Posts: 3823
Joined: Fri, 12. Aug 05, 20:46
x3tc

Post by Serial Kicked »

Kadatherion wrote:- Civilian jobs are flagged as "Destroy Out of Sector" in the placement tab. If that does what looks like, it would seem rather pointless to reduce 'em, since they would anyway not being called apart from those few active IS where you are. Or it actually isn't exactly what looks like? :P
Destroy OOS, doesn't mean they doesn't exists OOS, it means that the game engine can only delete them when you're not in the same sector :)

- They also seem to run either one of these three commands: add.wares.one.one, add.wares.few.one or add.wares.much.one. All are with function local.stationtostation (which seems natural since they shouldn't exist OOS and as such they don't even fly from one sector to another), with the exception of taxis which have a special dedicated function.
That add.wares made me wonder... do they actually TRADE or anyway transfer wares between stations in sector when they are active? As such they do in the end have an even slight use that, by disabling or heavily reducing 'em, could have noticeable repercussions in the long run?
[/quote]

add.wares are used to equip the ship with default wares (like passengers for taxi). One shot script launched at the creation of the ship.

The actual job is job.local.stationtostation, and it does what's written: flying randomly from a station to another one while station in the same sector. No trade, no nothing, simply pointless waste of CPU resources.
X3:TC/AP Pirate Guild 3 - Yaki Armada 2 - Anarkis Defense System

Anarkis Gaming HQ
Independent Game Development
X3 Scripting and Modding Station
User avatar
eldyranx3
Posts: 2178
Joined: Sat, 14. Jan 06, 21:29
xr

Post by eldyranx3 »

I asked this before a few months back in the 1st thread and didn't get a reply, so Im hoping someone will be kind hearted and offer some insight before I start random PMing ... :roll:

How do custom added gates work? I want to add / replace the TOA in Terran space, but the ones I code in only seem to work one directional and are broken. Yes, there is a script already that does that, but it seems to break new games.
Kadatherion
Posts: 1021
Joined: Fri, 25. Nov 05, 16:05
x4

Post by Kadatherion »

Ahh, now I understand, thanks a lot Serial Kicked :)

I'm taking the chance while I'm there to also do something like what was done in Unleashed by Jaga_Telesin (http://forum.egosoft.com/viewtopic.php?t=260355 here, thanks to Litcube for pointing it out), reducing also the free traders but balacing it deflagging the set average speed option most of them have, as suggested there by Aragon Speed.
A lot of useful infos on that topic should anyone be interested in adjusting his jobs file to keep more resources free for better things... like Serial Kicked's Pirate Guild :wink:
User avatar
Serial Kicked
Posts: 3823
Joined: Fri, 12. Aug 05, 20:46
x3tc

Post by Serial Kicked »

Thanks for the free advertisement :)

I just want to point out that the custom job file you linked isn't up to date with 2.7 (and probably 2.6 too). Some jobs are missing and seems mostly related to ships spawned after one of the most recent plots (don't quote me on that last part).

However, the data collected and general information provided by this topic are still accurate and interesting.
(an up to date "do it yourself" version is easy to do using the X3 Editor).
eldyranx3 wrote:Yes, there is a script already that does that, but it seems to break new games.
This script has 2 files. Remove the setup file, run X3, start your new game, open script editor, and run the other file manually (select it and press R). If you really want to know how it works, read this file :p
X3:TC/AP Pirate Guild 3 - Yaki Armada 2 - Anarkis Defense System

Anarkis Gaming HQ
Independent Game Development
X3 Scripting and Modding Station
Cycrow
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 22438
Joined: Sun, 14. Nov 04, 23:26
x4

Post by Cycrow »

Kadatherion wrote: - Civilian jobs are flagged as "Destroy Out of Sector" in the placement tab. If that does what looks like, it would seem rather pointless to reduce 'em, since they would anyway not being called apart from those few active IS where you are. Or it actually isn't exactly what looks like? :P
its pretty much what it looks like, civilian ships dont exist OOS, they are not like other ships that existing all the time, and trouble around the universe.

they simply exist in your current sector and fly around.

which is y when ppl do remove them from jobs, they rarely notice much different, other than a slight increase in fps if thier graphics card was previously struggling

its basically a myth that they use up alot of resources
User avatar
eldyranx3
Posts: 2178
Joined: Sat, 14. Jan 06, 21:29
xr

Post by eldyranx3 »

Serial Kicked wrote:This script has 2 files. Remove the setup file, run X3, start your new game, open script editor, and run the other file manually (select it and press R). If you really want to know how it works, read this file :p
Ah! Ive been looking at the script code for the setup file the whole time. I'll look at the other one. Thanks for the tip!
User avatar
Serial Kicked
Posts: 3823
Joined: Fri, 12. Aug 05, 20:46
x3tc

Post by Serial Kicked »

Cycrow wrote:..
So basically, they appear out of nowhere when opening a core sector in a sector map. The only value really used by civies in tjobs is the job.count per sector.

Oki.

I never checked the job count of civilians (i delete them anyway, IS they lower my fps in already busy sectors) and assumed that people who did those no civilian mods checked that for me before doing so. I assumed wrong.

As a side note, the previously discussed mod, reduce ALL job counts by more or less 33%.
X3:TC/AP Pirate Guild 3 - Yaki Armada 2 - Anarkis Defense System

Anarkis Gaming HQ
Independent Game Development
X3 Scripting and Modding Station
User avatar
ScRaT_GER
Posts: 1962
Joined: Tue, 8. Jan 08, 18:19
x3tc

Post by ScRaT_GER »

I have a short question concerning the RegEx Engine used by X3:TC.

I want to match roman digits I, V and X. So only if a string consists of these digits, I want a match.

The regular expression which should fullfill this need should be the following one: ^(I|V|X)+$
According to an online RegEx checker this works.

However it does not work with X3:TC.
I'm reading the RegEx from a T-File, where it is defined like this:

Code: Select all

<t id=10003">\^\(I\|V\|X\)+\$</t>
Reading this text from the T-File and logging it to the logbook shows, that everything is unescaped correctly.

But unfortunately it just won't match any romand digits. So XVII is not a match for ^(I|V|X)+$ - at least not in X3:TC.

Is it a mistake on my side - and if so, how can I make it work - or is the X3:TC RegEx Engine not capable of processing this RegEx?

Greetings,
ScRaT
User avatar
eldyranx3
Posts: 2178
Joined: Sat, 14. Jan 06, 21:29
xr

Post by eldyranx3 »

Im currently scripting in some Terran NPC Protein Paste stations to help prop up the Economy. What I have so far is:

Code: Select all

$PP = Create station type = Terran Protein Paste Blending Facility L Owner = Terran Add to =  Neptune x = 5000 y = -2000 z = 0
$PP = Create station type = Terran Protein Paste Blending Facility L Owner = Terran Add to =  Venus x = 5000 y = -2000 z = 0
$PP = Find Station in Galaxy = Start Sector = Saturn Class or Type = Terran Protein Paste Blending Facility L Race = Terran Flags = Null Ref Obj = Null Max Jumps = 10 Num = 10
$PP = Add Product to Factory or Dock = Protein Paste 
$PP = Add Product to Factory or Dock = Flavor Packs
$PP = Add Primary Resource to Factory = Energy Cells
But, when I run the test script, there are no products or resources in the newly created factories. Suggestions?
Last edited by eldyranx3 on Sat, 17. Jul 10, 16:59, edited 1 time in total.
User avatar
ScRaT_GER
Posts: 1962
Joined: Tue, 8. Jan 08, 18:19
x3tc

Post by ScRaT_GER »

Firstly: Is this script copied from the xml or did you rewrite it here? I'm asking because the commands are misspelled, so the script shouldn't even be loaded into the game.

Secondly: You are first creating two factories, but save them in one variable. Next thing you do, is to search for one of the factories, but save the return in the same variable.
When you now add products to that station, only one will get the new wares.

This is how it should work:

Code: Select all

$station = create station: type={Terran Protein Paste Blending Facility L} owner={Terran} addto=Neptune x=5000 y=-2000 z=0
$station -> add product to factory or dock: {Protein Paste}
$station -> add product to factory or dock: {Flavor Packs}
$station -> add product to factory or dock: {Energy Cells}
* Now create a new station and do the same thing
* ...
As you can see, there is no need to search for the factory, since you already saved it in the variable $station.

Greetings,
ScRaT
User avatar
eldyranx3
Posts: 2178
Joined: Sat, 14. Jan 06, 21:29
xr

Post by eldyranx3 »

Thanks for the suggestion, but the problem is I may want to add twenty of the stations in. Instead of just copying and pasting script, is there a way to build many of them, then add all those products and resources to all of them at once?

And yes, Im going from memory, and not the actual xml.

Return to “X³: Terran Conflict / Albion Prelude - Scripts and Modding”