[PROGRAM] X-Studio Script Editor [v1.08 : 14th Feb 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

Post Reply
Raaaak
Posts: 82
Joined: Fri, 29. Mar 13, 11:16
x3tc

Post by Raaaak » Tue, 19. Aug 14, 10:45

X-studio throws an error when I try to open a script from MK3 Traders Reloaded.

Code: Select all

IDS_UNHANDLED_DEBUG_ASSERTION: Debugging check failed : '"Unable to translate parameter types defined as DT_STATION" == FALSE' in translateParameterToString(..) on line 905 of .\Script Translation.cpp
IDS_ERROR_APPEND_LOCATION: translateParameterToString(..) has encountered an IDS_UNHANDLED_DEBUG_ASSERTION error (ID: 0702) in .\Script Translation.cpp, line 905
Attachment #1: 
Call Stack:
translateParameterToString(..) on line 817 of script translation.cpp
translateCommandToString(..) on line 407 of script translation.cpp
translateCommandNode(..) on line 209 of script translation.cpp
translateScriptFile(..) on line 1122 of script translation.cpp
translateScript(..) on line 1055 of script translation.cpp
threadprocLoadScriptFile(..) on line 1554 of script translation.cpp
The offending file is plugin.autotrade.check.stat.res.pck and a proper bug report has been submitted.

Does anyone know why this happens, and is there a work around?

User avatar
mr.bear
Posts: 444
Joined: Sat, 11. Dec 10, 01:38
x2

Post by mr.bear » Sat, 23. Aug 14, 23:09

I think they've used the in-game script editor to reference an in-game station 'Dala Na(Unbekanntes Objekt)', then commented the command and saved the script. It's left the script in a state where it contains live data. Try removing the commented line with the in-game editor, saving it and loading it with x-studio.

Code: Select all

*do if $station == Dala Na(Unbekanntes Objekt)
mr.bear
Rapunzel, Rapunzel, let down your bear...

User avatar
dizzy
Posts: 1019
Joined: Sun, 26. Sep 10, 06:00
x4

X-Studio requires admin privileges?

Post by dizzy » Thu, 13. Nov 14, 00:58

(sorry if this has been asked before)

This looks like a professional grade tool, I'm impressed to see this kind of work from a hobby programmer, fantastic piece of work!

I was looking to use a script editor (editing raw XML files got annoying quickly) and found your tool but unfortunately, when I try to run it Windows 7 prompts for the admin password. This is something some people do (mark their .exe with manifests which include "requireAdministrator" privileges requirements) because the tool might need access to protected directories (like "Program Files (x86)") and the world is full of dumb people who can't set privileges in there to give themselves write access and then bother the poor developers that the thing is not working!!111oneone :)

However, knowing that I did give myself write permissions on the Terran Conflict installation directory (I edit files in there directly with Notepad++ for example) I shouldn't need to run X-Studio as admin so I used my favourite Resource Editor, open the X Studio.exe and sure enough, it has a "requireAdmin" manifest. I remove that and save.

But now it gets strange. If I run X-Studio.exe again, it again prompts for admin, what the hell. I open the .exe again in the resource editor and again it has the requireAdmin bits, what is going on I just removed those. So I save to another executable and I even reload it (after restarting the Resource Editor) and indeed it's now missing the requireAdmin requirement but again when I run it, I get prompted and the requirement is added to the manifest file.

I'm confused... so I have a couple of questions:
1. why does X-Studio require admin privs?
2. how can I run it without admin privileges?

Thanks!

User avatar
mr.bear
Posts: 444
Joined: Sat, 11. Dec 10, 01:38
x2

Post by mr.bear » Thu, 25. Dec 14, 11:26

Merry christmas everybody!

I've been consumed by RL & my day job for the last six months, and I don't know when, or even if, I'll have spare time to work on X-Studio or X-Studio II from now on, especially since I may move over to Elite Dangerous if the game is popular.

sorry guys, but X-Studio 1 was an especially huge sink on my time, which I just don't have anymore.

mr.bear
Rapunzel, Rapunzel, let down your bear...

User avatar
DrBullwinkle
Posts: 5715
Joined: Sat, 17. Dec 11, 01:44
x3tc

Post by DrBullwinkle » Thu, 25. Dec 14, 12:28

Thanks for doing as much as you have done so far, Mr. Bear.

X-Studio is an absolute joy to work with. It frees the developer to be creative and work on the code, rather than having to worry about the editor.

Thank you.

And Merry Christmas to you, as well!

DrBrain
Posts: 2
Joined: Tue, 4. Oct 11, 22:51
x3tc

Post by DrBrain » Wed, 7. Jan 15, 16:28

Hello mr.bear,

I've tried to use your x-studio to modify X2 (1.4/1.5/BonusPackage), each version x-studio failed to load. The reason is -AFSIK- when trying to load \types\TDocks.pck file which is not part of X2, btw. neither the folder \types is.

The error message log (excerpt):

Code: Select all

0x1838: Loading object definition file 'types\TDocks.pck'
0x1838: IDS_TFILE_VERSION_UNSUPPORTED: The object type definitions file 'types\TDocks.pck' is from an unsupported version of X² The Threat, please update to the lastest version
0x1838: Successfully loaded 0 docks from the object type definitions file 'types\TDocks.pck'
I guess x-studio does not support X2 natively ?! Or did I miss something to install?

Greetings DrBrain

DrBrain
Posts: 2
Joined: Tue, 4. Oct 11, 22:51
x3tc

Post by DrBrain » Mon, 19. Jan 15, 01:52

@mr.bear

first of all I like to thank you for precious effords to bring this editor alive. Unfortunately your editor, which seems to me superior to Exscriptor does not load with an X2 installation only, due to the fact (I guess) some X3 resource files does not exists.

Is there any advice or help to solve this problem, please? I really like to use your editor, really!

If there is any switch or something like that to fix it? I appreciate to here from you, thanks.

User avatar
Joubarbe
Posts: 4796
Joined: Tue, 31. Oct 06, 12:11
xr

Post by Joubarbe » Sat, 28. Mar 15, 10:49

Hey mr.bear (and others). If you're still alive, I'm wondering how your macros system work. Is it editable ? For instance, if I wanted to add a "select/case/default" statement ?

User avatar
jack775544
Posts: 1277
Joined: Tue, 13. Dec 11, 08:27
x4

Post by jack775544 » Mon, 30. Mar 15, 12:23

Joubarbe wrote:Hey mr.bear (and others). If you're still alive, I'm wondering how your macros system work. Is it editable ? For instance, if I wanted to add a "select/case/default" statement ?
I don't believe so. As far as I know the only way you could do it would be to go into the source code and add it manually.

The other problem is that the source code version is several behind the release build.
1940s - Various "computers" are "programmed" using direct wiring and switches. Engineers do this in order to avoid the tabs vs spaces debate.

GlassDeviant
Posts: 291
Joined: Sun, 4. Nov 12, 12:06
x3tc

Post by GlassDeviant » Mon, 13. Apr 15, 13:55

mr.bear wrote:If you want to run the program on a computer without X, you just need to copy the following files into a folder and select that as your 'game folder' in Preferences. (Make sure you put them in their proper subfolders: 'mov', 't' and 'types')
  • t\0001-L044.pck (or .XML) (Main language strings)
    mov\00044.pck (or .XML) (Speech clip definitions)
    types\sounds.pck (or .TXT) (Sound effect definitions)
    types\videos.pck (or .TXT) (Video clip definitions)
    types\TDocks.pck (or .TXT)
    types\TFactories.pck (or .TXT)
    types\TShips.pck (or .TXT)
    types\TLaser.pck (or .TXT)
    types\TShields.pck (or .TXT)
    types\TMissiles.pck (or .TXT)
    types\TWareE.pck (or .TXT)
    types\TWareN.pck (or .TXT)
    types\TWareB.pck (or .TXT)
    types\TWareF.pck (or .TXT)
    types\TWareM.pck (or .TXT)
    types\TWareT.pck (or .TXT)
My X3AP has only one of these files, mov\00044.pck.
bibo ergo sum

User avatar
X2-Illuminatus
Moderator (Deutsch)
Moderator (Deutsch)
Posts: 24950
Joined: Sun, 2. Apr 06, 16:38
x4

Post by X2-Illuminatus » Mon, 13. Apr 15, 13:59

GlassDeviant wrote:Where is the types folder? My X3AP has no such folder.
Like most game files, the types folder can be found within the cat/dat files. Use the Virtual File System (VFS) from X3 Editor 2 to extract the newest files from that folder.
Nun verfügbar! X3: Farnham's Legacy - Ein neues Kapitel für einen alten Favoriten

Die komplette X-Roman-Reihe jetzt als Kindle E-Books! (Farnhams Legende, Nopileos, X3: Yoshiko, X3: Hüter der Tore, X3: Wächter der Erde)

Neuauflage der fünf X-Romane als Taschenbuch

The official X-novels Farnham's Legend, Nopileos, X3: Yoshiko as Kindle e-books!

GlassDeviant
Posts: 291
Joined: Sun, 4. Nov 12, 12:06
x3tc

Post by GlassDeviant » Mon, 13. Apr 15, 14:13

Cool, thanks!
bibo ergo sum

GlassDeviant
Posts: 291
Joined: Sun, 4. Nov 12, 12:06
x3tc

Post by GlassDeviant » Mon, 13. Apr 15, 17:24

So I run X3 Editor 2, choose "Open From VFS", then just save it to a types folder in the uh..folder where I am going to be holding my mods while I edit them?
bibo ergo sum

User avatar
jack775544
Posts: 1277
Joined: Tue, 13. Dec 11, 08:27
x4

Post by jack775544 » Tue, 14. Apr 15, 00:19

The X VFS does not require the types folder to be in a cat/dat pair.
If you want you can create a types folder in your game directory (X3TC/addon for X3AP) and place it in there and it will load into the game.

The best example of this being done in the game is the t folder. Most scripts will store their text files in the t folder of the game directory, but if you go through the base game cat/dat files then you will see that in either 01.cat or 02.cat there will be a t folder holding all of the vanilla strings. In the end the principal is the same for thing that are to be saved in then types folder as well.
1940s - Various "computers" are "programmed" using direct wiring and switches. Engineers do this in order to avoid the tabs vs spaces debate.

GlassDeviant
Posts: 291
Joined: Sun, 4. Nov 12, 12:06
x3tc

Post by GlassDeviant » Tue, 14. Apr 15, 02:30

I discovered that I can just let it use the game files where they sit, and then wander through my uninstalled mod folders however I please, so that makes things easier. Unfortunately two of the three conflicts I found are just whitespace issues, the code is identical. The third one can't even be investigated as nothing will open the file from one of the two mods, so I think it might be corrupted.

...which puts me back to square one, trying to find out why my game is always messed up internally in some way that I cannot discern, but breaks CAG/CLS waypoint setup.

Well, back to the drawing board.
Last edited by GlassDeviant on Tue, 14. Apr 15, 13:44, edited 1 time in total.
bibo ergo sum

GlassDeviant
Posts: 291
Joined: Sun, 4. Nov 12, 12:06
x3tc

Post by GlassDeviant » Tue, 14. Apr 15, 13:44

How can I view two XML files in X-Studio side by side rather than having to flip between tabs?
bibo ergo sum

User avatar
jack775544
Posts: 1277
Joined: Tue, 13. Dec 11, 08:27
x4

Post by jack775544 » Wed, 13. May 15, 08:11

mr bear,
I am finally learning how to properly do C programming (even though it is for an 8-bit micro controller but the principals are the same) and I have one observation.
How the hell are you still sane?

Ok, now I have that out of my system you can carry on ;)
1940s - Various "computers" are "programmed" using direct wiring and switches. Engineers do this in order to avoid the tabs vs spaces debate.

Gqqnbig
Posts: 66
Joined: Fri, 12. Jul 13, 14:08

Post by Gqqnbig » Tue, 8. Sep 15, 01:24

IDS_SCRIPT_PROPERTY_MISSING: One or more of the mandatory extended script properties are missing or invalid
IDS_SCRIPT_ARGUMENT_TYPE_NAME_INVALID: The script argument 'targetRace' uses an unknown data type 'Var/种'
IDS_ERROR_APPEND_LOCATION: createArgumentFromNode(..) has encountered an IDS_SCRIPT_ARGUMENT_TYPE_NAME_INVALID error (ID: 0214) in Script Arguments.cpp, line 56

The script I want to open is here.

https://www.dropbox.com/s/x3yjlm1mwovac ... l.xml?dl=0

User avatar
mr.bear
Posts: 444
Joined: Sat, 11. Dec 10, 01:38
x2

Post by mr.bear » Sat, 12. Sep 15, 11:56

@Gqqnbig,

Looks like it was edited using a Chinese language installation. X-studio doesn't support Chinese. You'll have to open it in eXscriptor on a non-Chinese installation, save it, then load it in X-Studio.

mr.bear
Rapunzel, Rapunzel, let down your bear...

User avatar
mr.bear
Posts: 444
Joined: Sat, 11. Dec 10, 01:38
x2

Post by mr.bear » Mon, 14. Sep 15, 21:42

@jack775544: sorry for taking 6 months to reply!
yes, writing all that C did make me loopy. I tried to keep it as structured as possible by having producer, destruction, mutator, and observer functions. I taught me a lot about Win32 developement at least. Although I'd never, ever do it again.

You're writing for 8-bit micro-controllers? cool. what are they for?
I got very much into C++, and I'm currently writing a textbook on it.

mr.bear
Rapunzel, Rapunzel, let down your bear...

Post Reply

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