[SCR] Custom Start v1.4.0 (21-04-14)

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

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

Shimrod
Posts: 907
Joined: Tue, 18. Feb 03, 01:43
x4

Post by Shimrod »

I've no plan to maintain an SPK version myself but I'm fine with it being repackaged, bundled, or otherwise re-hosted.
User avatar
Createse
Posts: 58
Joined: Fri, 20. Mar 09, 23:28
x4

Post by Createse »

Thank you and kudos on your work, your smart turrets package in particular is something special.
User avatar
joelR
Posts: 2008
Joined: Mon, 9. Jul 07, 23:33
x3tc

Post by joelR »

Shimrod, I have never been able to get this to work. I suspect it may be something thats loading in a new start that blocks this. Is it possible to trigger the menu through the script editor?
User avatar
TTD
Posts: 11165
Joined: Sun, 6. Jul 08, 10:29
x4

Post by TTD »

joelR wrote:Shimrod, I have never been able to get this to work. I suspect it may be something thats loading in a new start that blocks this. Is it possible to trigger the menu through the script editor?
Not sure of the answer to your question, but have you installed this script to the correct folder as listed above,in a fresh game install?
iirc the menu should only be available when you first start a new game...no good trying to load a saved game and expecting to adjust anything ;-)
I have just made a new Non-steam folder,using the new exec from Egosoft.
I installed this script in the correct place and have no problem.
The game started as normal, after selecting the start.
Then the menu came up, I adjusted what I wanted, and the game continues .
User avatar
joelR
Posts: 2008
Joined: Mon, 9. Jul 07, 23:33
x3tc

Post by joelR »

Ya its all installed correctly. And I started a new game.

Cant figure out what the issue could be either.
Shimrod
Posts: 907
Joined: Tue, 18. Feb 03, 01:43
x4

Post by Shimrod »

The menu can't be launched directly, but you can make a version that can be launched via script editor as follows:
1. Take a copy of the script renamed so it's not prefixed with 'setup', so it won't run automatically. This might need to be done via 'save as' in X-Studio in case it needs recompiled with the new name.
2. Either Delete everything from top of the script up until line 35 (which has comment 'add custom start logic here'), or put 'gosub setup.start:' at the top.

This is the mechanism it uses to ensure a one-time popup at game creation:

First time the setup script ever runs it will:
1. Write a global variable to block future executions in that savegame.
2. If playership exists, assume it's a gameload rather than gamestart and exit.
3. Create a neutral nav beacon in sector null and run the setup script on it as a new task.
4. Exit.

This setup script on the nav beacon will:
a. Poll at 1 second intervals until the player ship exists. Polls 10 times before giving up (sanity check).
b. Launch the menu
c. Destruct the nav beacon

So possibly in your case
- The playership exists on first run (step 2), maybe delayed by some other setup script that doesn't want to exit. Adding a call to write to player logbook into the script if that occurs should highlight this.
- The nav beacon gets cleaned up by some well meaning mod before the menu fires. Adding write to logbook calls per iteration should show whether all 10 iterations occur.
- The modded game or hardware is so slow to initialize it passes the 10 second sanity check on the polling loop. Try editing line 3 and set it to 30 seconds, then start a new game.

I've never seen it fail to pop up myself. I even use it on TC, even though some of my library script laser/missile spawning logic won't produce ideal results.
Virtualaughing
Posts: 2003
Joined: Sat, 14. Jun 08, 20:40
x4

Post by Virtualaughing »

Speaking of temptation when i read this topic.....
Now i have to face a challenge. "do not go modified you fool" says my little angel in my mind :D
X to X3 is MENU SUPERIOR!
I think Egosoft has already worked out our doom, because Xenon AI will reach the stars! :D
User avatar
TTD
Posts: 11165
Joined: Sun, 6. Jul 08, 10:29
x4

Post by TTD »

@ Virtualaughing

If you have exhausted X with all the official starts, then using this, coupled with Cycrow's Cheat package, will give you an extensive range of game-play.
kvntvan
Posts: 4
Joined: Tue, 21. May 13, 05:45
x3ap

Post by kvntvan »

So I installed this mod recently and played a new game on XRM 1.29 and a few other mods and noticed a weird error occurring, some of the stations would have <Invalid> L Alpha or <Invalid> M Gamma as their names instead of actually station names. Also the Showrooms (special XRM shipyards) would appear as <INVALID> XXL and a few ships would show up as weird code names like #FECAS or something like that.

It began to create an error with my UT's because they weren't appearing to the AI yet were still being docked at, causing lots of UT standbyes.

After an extensive amount of time uninstalling and reinstalling the game/mod files/scripts and plugins, I found the culprit to be this custom start script.

Has anyone had similar problems with XRM and this mod?
Shimrod
Posts: 907
Joined: Tue, 18. Feb 03, 01:43
x4

Post by Shimrod »

With custom start being entirely script based rather than modifying game files, it's highly unlikely to be responsible for the symptom as described.

The menu does allow you to spawn any station from the list of stations available to the script API, so it is possible to select and spawn weird undefined stations, but other than that I've no insight into this.

There are some ships in game with names starting with hashes, meant to be rogue terraformer ships (#deca, #cefa etc)
MassterJ
Posts: 25
Joined: Thu, 29. May 08, 22:50
x4

Post by MassterJ »

hello to all i have see someone have the same error as me :

i have the menu but all stuff are nammed <Read text>

i have see it's due to the language used on my game hmmm i use french language how can i resolve that please for french?

on the way i have some others scripts and menun appears well in english these ones are from XRM, and Salvage script so .... if the menu appear correctly for this script it's can be excellent


any idea?

i have X3 AP 3.0 (french) with XRM 1.29c and one salvagee script 4.11 named SCS 4.11


MJ
Shimrod
Posts: 907
Joined: Tue, 18. Feb 03, 01:43
x4

Post by Shimrod »

You can make the English text appear in the French game by:

1. Copy 9051-L044.xml to 9051-L033.xml
2. Change this line at the top of the file:

Code: Select all

<language id="44">
To:

Code: Select all

<language id="33">
I don't otherwise have any real localized versions of the strings file.
MassterJ
Posts: 25
Joined: Thu, 29. May 08, 22:50
x4

Post by MassterJ »

thank you for the fast reply

it's work great and suddenly it's more easier to use ^^


mj
nexenon
Posts: 3
Joined: Sat, 18. May 13, 23:57

Post by nexenon »

Wow this looks like about the best way to end the start game grind without enabling the script editor. I would love to DL it but when I click the link it takes me to:

Code: Select all

http://www.x1tp.com/root/index.php?option=com_jdownloads&Itemid=6&view=finish&cid=1268&catid=124
And this pops up in my browser:

Database Error: Unable to connect to the database:The MySQL adapter "mysql" is not available.

Could you please post another link if possible? I am looking forward to trying this out.

:)
Shimrod
Posts: 907
Joined: Tue, 18. Feb 03, 01:43
x4

Post by Shimrod »

I aim to have it re-hosted sometime this evening after work.

Update: now re-hosted
nexenon
Posts: 3
Joined: Sat, 18. May 13, 23:57

Post by nexenon »

Thanks for the new link Shimrod! :) And so fast too!

I have it installed now and it seems to be working. Thanks again, this has convinced me to start a new AP game. (this time no tempting script editor enabled 8) )
Shimrod
Posts: 907
Joined: Tue, 18. Feb 03, 01:43
x4

Post by Shimrod »

No problem. The BT cloud hosting isn't too bad particularly since it's free with my ISP package, though they'll have me over a barrel for keeping the subscription going :)

They seem to have gone to the windows 8 school of UI design though.

"I know, let's put a single row of giant vacant icons at the top of the screen with no useful information on them and leave 90% of vertical space blank. That way a user can resize their browser window in a pencil-like configuration, and continue working underneath it!"

"Great idea, cloud driven productivity! But Should we put in a download counter so the user can see how many people downloaded their file?"

"Nah that would detract from the beauty of the giant blank file icon that occupies the entire page, when delving into the file. It might confuse the user and lead to support calls. Instead let's aim for what's clearly the 80% use-case and put <fullscreen> and <play all> buttons underneath the zip file icon."
User avatar
heratik
Posts: 1210
Joined: Tue, 3. May 11, 16:31
x3tc

Post by heratik »

Hi Shimrod, this looks amazing, one question, is there a TC version of this mod, or any way of making it compatible with TC?
Shimrod
Posts: 907
Joined: Tue, 18. Feb 03, 01:43
x4

Post by Shimrod »

It'll work on TC, I've used it myself. Probably the worst that it might do is pick a sub-standard laser configuration when spawning ships, since the equipping algorithm uses DPS data unavailable to TC scripting APIs.

I've been meaning to load up the scripts and try and isolate AP-specific functionality, working around stuff like lack of a 'get minimum' script API with the equivalent, etc. Give it a try.
User avatar
DrBullwinkle
Posts: 5715
Joined: Sat, 17. Dec 11, 01:44
x3tc

Post by DrBullwinkle »

Shimrod wrote:"Should we put in a download counter so the user can see how many people downloaded their file?"

"Nah that would detract from the beauty of the giant blank file icon that occupies the entire page
:rofl:
Post Reply

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