[PROGRAM] X-Studio 2 Script Editor [Beta III : 30th Mar 14]
Moderators: Moderators for English X Forum, Scripting / Modding Moderators
2 Things:
1) I am not able to use X-Studio 2, because it crashes the moment I am starting it.
OS: Win7 64bit
Game: TC v 3.2
I followed the instructions, downloaded and executed the x86 Redistributable.
Everything was ok until I told X-Studio 2 the location of the game folder.
It tryed to load some language file, then it no longer worked.
Here an image for clarification.
Now every time I start X-Studio 2, it crashes the same way.
2) As I am not able to use X-Studio 2, I am still using X-Studio 1 v 1.08. So - if the following bugs have already been fixed, forget it
Bug in descriptions detected (producing a LOT of headace to me untill I sorted that out):
The descriptions to the random number commands are WRONG:
<ret/var> random value between <Var/Number1> and <Var/Number2>
Your description:
A random number, that coud be <Var/Number1>, <Var/Number2>, or any number in between.
Correct description:
A random number, that coud be <Var/Number1>, or any number between <Var/Number1> and <Var/Number2>.
<ret/var> random value from zero to <Var/Number>
Your description:
A random number, that coud be zero, <Var/Number2>, or any number in between.
Correct description:
A random number, that coud be zero, or any number between <Var/Number1> and <Var/Number2>.
In both cases the number will NEVER be <Var/Number2>!! I proved that by extensive testing.
1) I am not able to use X-Studio 2, because it crashes the moment I am starting it.
OS: Win7 64bit
Game: TC v 3.2
I followed the instructions, downloaded and executed the x86 Redistributable.
Everything was ok until I told X-Studio 2 the location of the game folder.
It tryed to load some language file, then it no longer worked.
Here an image for clarification.
Now every time I start X-Studio 2, it crashes the same way.
2) As I am not able to use X-Studio 2, I am still using X-Studio 1 v 1.08. So - if the following bugs have already been fixed, forget it
Bug in descriptions detected (producing a LOT of headace to me untill I sorted that out):
The descriptions to the random number commands are WRONG:
<ret/var> random value between <Var/Number1> and <Var/Number2>
Your description:
A random number, that coud be <Var/Number1>, <Var/Number2>, or any number in between.
Correct description:
A random number, that coud be <Var/Number1>, or any number between <Var/Number1> and <Var/Number2>.
<ret/var> random value from zero to <Var/Number>
Your description:
A random number, that coud be zero, <Var/Number2>, or any number in between.
Correct description:
A random number, that coud be zero, or any number between <Var/Number1> and <Var/Number2>.
In both cases the number will NEVER be <Var/Number2>!! I proved that by extensive testing.
- Aldebaran_Prime
- Posts: 1386
- Joined: Sat, 20. Feb 10, 17:47
hey Nicoman,
could you send me 0901-L044.pck language file please? X-Studio 2 doesn't seem to be able to load it.
re: the random number thing: yeah several people have mentioned this, it only generates a random number x -> y if y is a hard coded number. If y is a variable then it produces x -> (y-1). sorry about that. x-studio 2 doesn't work that way.
Aldebaran_Prime: could you send me the language file x-studio 2 loads immediately as it crashes? see nicoman's picture for an example.
mr.bear
could you send me 0901-L044.pck language file please? X-Studio 2 doesn't seem to be able to load it.
re: the random number thing: yeah several people have mentioned this, it only generates a random number x -> y if y is a hard coded number. If y is a variable then it produces x -> (y-1). sorry about that. x-studio 2 doesn't work that way.
Aldebaran_Prime: could you send me the language file x-studio 2 loads immediately as it crashes? see nicoman's picture for an example.
mr.bear
Rapunzel, Rapunzel, let down your bear...
thanks Nicoman, I'll try and work out what X-Studio doesn't like about that file.
I've added the project to google code, I don't really expect contributions but they're welcome nonetheless. Link to repository is in the 'source code' section on first page.
mr.bear
UPDATE: I've added lots of missing files to the google code project, and set up the wiki/issues and listed the status of the issues from the first page. It should now be usable.
I've added the project to google code, I don't really expect contributions but they're welcome nonetheless. Link to repository is in the 'source code' section on first page.
mr.bear
UPDATE: I've added lots of missing files to the google code project, and set up the wiki/issues and listed the status of the issues from the first page. It should now be usable.
Rapunzel, Rapunzel, let down your bear...
- Aldebaran_Prime
- Posts: 1386
- Joined: Sat, 20. Feb 10, 17:47
Here the language file where XS2 crashes. Hope you can download it - I never tried OneDrive to share something before...
"https://onedrive.live.com/?cid=FF929D21 ... 929657!103"
"https://onedrive.live.com/?cid=FF929D21 ... 929657!103"
-
- Posts: 2880
- Joined: Fri, 17. Feb 06, 04:55
Crash when trying to load the Steam version of X3:Reunion. Point of crash is when it's trying to load the 440001 language file.
Crash report:
The OP says to dl the x86 version of the MSVC 13 redistribution. I did, but your program seems to ignore it in favor of 12.
However, when I check the Resource monitor for the program, it shows version 10 is also loaded by XStudio 2 beta 3. Should that happen?
Crash report:
Code: Select all
Problem signature:
Problem Event Name: APPCRASH
Application Name: XStudio2.exe
Application Version: 1.0.0.0
Application Timestamp: 533836b2
Fault Module Name: MSVCR120.dll
Fault Module Version: 12.0.21005.1
Fault Module Timestamp: 524f7ce6
Exception Code: 40000015
Exception Offset: 000a7676
OS Version: 6.1.7601.2.1.0.256.48
Locale ID: 1033
Additional Information 1: 2d36
Additional Information 2: 2d367e0fd672fe98d183554358525913
Additional Information 3: 93ef
Additional Information 4: 93ef5756abf3ec248f2b152498ee3b6e
However, when I check the Resource monitor for the program, it shows version 10 is also loaded by XStudio 2 beta 3. Should that happen?
JakeSnake5,
the honest answer is I don't know. I'll have to look into it.
However on another note - are you sure it's crashing for the 440001 file and not the file immediately afterwards? eg. your lowest numbered language file after 0001. Please can you post the 'Console.rtf' file generated in the x-studio folder? (or email xstudio.development@gmail.com)
Sorry for the delay btw
mr.bear
UPDATE: Nicoman35/AldeberanPrime - I've fixed the issues you were having, they'll be included in the next update
the honest answer is I don't know. I'll have to look into it.
However on another note - are you sure it's crashing for the 440001 file and not the file immediately afterwards? eg. your lowest numbered language file after 0001. Please can you post the 'Console.rtf' file generated in the x-studio folder? (or email xstudio.development@gmail.com)
Sorry for the delay btw
mr.bear
UPDATE: Nicoman35/AldeberanPrime - I've fixed the issues you were having, they'll be included in the next update
Rapunzel, Rapunzel, let down your bear...
-
- Posts: 2880
- Joined: Fri, 17. Feb 06, 04:55
I don't really need XS2 for Reunion, Exscriptor handles it just fine. It's the 'do if's that give it issues and I use XS2 for in TC and AP.
Other issues:
I also have encountered, Cycrows Plugin Manager causes problems with the t file 0901-L044.pck and the types file TWareT.pck. Specifically, XS2 crashes when it tries reading them.
Posabily because they are packed. When I remove them from their respective directories, XStudio 2 has no trouble loading all other files.
The missing text file isn't a major issue, but the data in the TWareT file means some scripts have invalid data that they reference from it.
I then UN-pck'd them, replacing the pcks with the xmls, and XS2 loaded them ok. There were several non-critical errors with the TwareT, but that's understandable. So something with the pack format is confusing XS2 enough to cause it to crash.
I also have a file from the MARS scripts that it just won't save, with a couple of errors. 1 is typical of external editors I think, but another is odd.
First one, is the use of ' in a string. Specifically:
XS2 interprets the 2nd ' as the end of the string, and get's lost there after. Exscriptor has issues with strings like this as well, so I don't know how that could be resolved (other than using a place holder and typing the string in while in the game, after all editing is done).
Another is reported as: type mismatch - '[THIS]' is not a valid Var/Script Data Type '[THIS]'
This appears in the script line:
I do believe it's the 2nd [THIS] (it shows in red, not yellow) that it has trouble with.
Last problem is the search function. I'm not sure it's working right. I tried to find the word 'Repair' in Current Document (actually, tried all 'Look In' sections, only Scripts worked) and got the error:
The operation is invalid: Unsupported target type
Sink: GUI::Windows::FindDialog::OnFind_Click() on line 213
Source Logic::Threads::SearchWorkerData::SearchWorkerData() on line 52
Searching in Scripts seems to work just fine.
Beyond those problems, I find XS2 excellent. Thanks for the program.
EDIT:
The TWareT.pck file
Other issues:
I also have encountered, Cycrows Plugin Manager causes problems with the t file 0901-L044.pck and the types file TWareT.pck. Specifically, XS2 crashes when it tries reading them.
Posabily because they are packed. When I remove them from their respective directories, XStudio 2 has no trouble loading all other files.
The missing text file isn't a major issue, but the data in the TWareT file means some scripts have invalid data that they reference from it.
I then UN-pck'd them, replacing the pcks with the xmls, and XS2 loaded them ok. There were several non-critical errors with the TwareT, but that's understandable. So something with the pack format is confusing XS2 enough to cause it to crash.
I also have a file from the MARS scripts that it just won't save, with a couple of errors. 1 is typical of external editors I think, but another is odd.
First one, is the use of ' in a string. Specifically:
Code: Select all
send incoming message 'MARS 9000: I'm sorry Dave, I'm afraid I can't do that.' to player: display it=[TRUE]
Another is reported as: type mismatch - '[THIS]' is not a valid Var/Script Data Type '[THIS]'
This appears in the script line:
Code: Select all
$RefPos = [THIS] -> call script 'lib.ut.pos.from.2.grades.and.rad' : alpha=null beta=null dis=-8000 pos.argument=[THIS]
Last problem is the search function. I'm not sure it's working right. I tried to find the word 'Repair' in Current Document (actually, tried all 'Look In' sections, only Scripts worked) and got the error:
The operation is invalid: Unsupported target type
Sink: GUI::Windows::FindDialog::OnFind_Click() on line 213
Source Logic::Threads::SearchWorkerData::SearchWorkerData() on line 52
Searching in Scripts seems to work just fine.
Beyond those problems, I find XS2 excellent. Thanks for the program.
EDIT:
The TWareT.pck file
hi JakeSnake,
Yes the current version can't handle packed files, that's the problem Nicoman and AldeberanPrime were having, but I've fixed that now. (0901-L044.pck + TWareT.pck)
apostrophes in strings will take me a little while to figure out, so i'll open an issue for that and work on it later.
the reason this doesn't compile is due to a new compiler setting: type checking script-call arguments. (You can disable it in preferences) It's saying the type of the "pos.argument" argument is "Var/Script Data Type" (eg. Int, String, Array) and you're trying to pass [THIS], which is inappropriate.
mr.bear
Yes the current version can't handle packed files, that's the problem Nicoman and AldeberanPrime were having, but I've fixed that now. (0901-L044.pck + TWareT.pck)
apostrophes in strings will take me a little while to figure out, so i'll open an issue for that and work on it later.
Code: Select all
$RefPos = [THIS] -> call script 'lib.ut.pos.from.2.grades.and.rad' : alpha=null beta=null dis=-8000 pos.argument=[THIS]
mr.bear
Rapunzel, Rapunzel, let down your bear...
-
- Posts: 2880
- Joined: Fri, 17. Feb 06, 04:55
I always wondered why Exscriptor used the apostrophes for string identification, and XS/2 follows suit.
I'd have thought that using " to begin/end a string would be better, as I don't know why anybody would use it in a string to start with, so would, logically, not cause problems. Or, at least, not as many.
Leave it to contractions to cause a script editor problems.
As for the script call using [THIS] as an argument being improper, this hasn't stopped people from doing it, and the game seems to accept it. Weird.
Took me a couple tries to figure out which argument check was doing it
I'd have thought that using " to begin/end a string would be better, as I don't know why anybody would use it in a string to start with, so would, logically, not cause problems. Or, at least, not as many.
Leave it to contractions to cause a script editor problems.
As for the script call using [THIS] as an argument being improper, this hasn't stopped people from doing it, and the game seems to accept it. Weird.
Took me a couple tries to figure out which argument check was doing it
There are reasons to use " in a string, which is why the " escape sequence exists in practically all programming languages, but we wont to too far into that, suffice to say ' is used because the game used ' - in python for example you can use '"' to define a string with a " in it, or "'" to define a string with a ' in it. If you want to represent the name of an object within a string, you need to use " if you want to be grammatically correct.Jakesnake5 wrote:I always wondered why Exscriptor used the apostrophes for string identification, and XS/2 follows suit.
I'd have thought that using " to begin/end a string would be better, as I don't know why anybody would use it in a string to start with, so would, logically, not cause problems. Or, at least, not as many.
Leave it to contractions to cause a script editor problems.
As for the script call using [THIS] as an argument being improper, this hasn't stopped people from doing it, and the game seems to accept it. Weird.
Took me a couple tries to figure out which argument check was doing it
However ignoring all of the above, its not a good idea to hard-code " or ' into X strings, a supported and better solution would be to use a TextFile:
<t id=1>"%s" - Hello World</t>
Then use the sprintf with textfile lookup - This both provides you with grammar, and translate-ability.
As a matter a fact, the game does prevent passing invalid data (in some limited circumstances) to a script that requests a specific type, when you go to select the passed argument, for say perhaps "number" the script editor in-game will only allow you to input a number. This is meaningless however, as its just a loose guide to what the arguments are ment to be, a variable is a variable in the MSCI, and anything can be passed anywhere - even when error prone or inappropriate.
[ external image ]
"One sure mark of a fool is to dismiss anything that falls outside his experience as being impossible."
―Farengar Secret-Fire
"One sure mark of a fool is to dismiss anything that falls outside his experience as being impossible."
―Farengar Secret-Fire
-
- Posts: 2880
- Joined: Fri, 17. Feb 06, 04:55
Would help if thing's behaved themselves, but we're stuck with it. However, the xml code for the offending text string is:
As you can see, it defines the text string as a <var>, and exits with </var>, so the game, (and XS) knows what it is. The trouble XS runs into is processing it for compile. It just doesn't work right since XS has nothing to tell it the whole string is a variable, so it hit's a wall with the extra 's.
Maybe XS2 needs to utilize a style sheet like x2script.xsl, to define what we see like the browser does when you double click a script xml. The style sheet tells the browser how to display the code properly, regardless of what that code looks like.
Another tactic, would be to assign the string to a variable, then use the variable instead of a text string.
Actually, I'm surprised that the guys who did M.A.R.S. didn't put that text in the T file and pull it to a var that way.
Trouble is, the way XStudio handles it now, is it forgets that there is a string variable there, and can't handle it when you try to save it.
Maybe if XS were to put a hidden 'flag' of some sort at the beginning and end of the string, and know to just ignore what the string contains when parsing. The game has to do something like that itself.
Would have to put in a selector to identify whether you were typing a variable name or a text string, just to get the data right.
Code: Select all
<line linenr="784" indent=" "><text>send incoming message </text><var>'MARS 9000: I'm sorry Dave, I'm afraid I can't do that.'</var><text> to player: display it=</text><var>[TRUE]</var></line>
Maybe XS2 needs to utilize a style sheet like x2script.xsl, to define what we see like the browser does when you double click a script xml. The style sheet tells the browser how to display the code properly, regardless of what that code looks like.
Another tactic, would be to assign the string to a variable, then use the variable instead of a text string.
Actually, I'm surprised that the guys who did M.A.R.S. didn't put that text in the T file and pull it to a var that way.
Trouble is, the way XStudio handles it now, is it forgets that there is a string variable there, and can't handle it when you try to save it.
Maybe if XS were to put a hidden 'flag' of some sort at the beginning and end of the string, and know to just ignore what the string contains when parsing. The game has to do something like that itself.
Would have to put in a selector to identify whether you were typing a variable name or a text string, just to get the data right.
i think the best way to solve this problem is by using an escape character for apostrophes.
btw the script-xml you quoted is only used by the browser - it uses a transforming style sheet to convert xml to html. that entire section is ignored by the game.
mr.bear
btw the script-xml you quoted is only used by the browser - it uses a transforming style sheet to convert xml to html. that entire section is ignored by the game.
mr.bear
Rapunzel, Rapunzel, let down your bear...
-
- Posts: 2880
- Joined: Fri, 17. Feb 06, 04:55
Do you mean adding an esc char before the first and last apostrophes in the string, so XS knows to ignore the ones in the middle? Or replacing ALL of apostrophes? Or just the ones inside the string?mr.bear wrote:i think the best way to solve this problem is by using an escape character for apostrophes.
mr.bear
The first and last methods have merit. The 2nd would be a bit messier
-
- Posts: 2880
- Joined: Fri, 17. Feb 06, 04:55
- DrBullwinkle
- Posts: 5715
- Joined: Sat, 17. Dec 11, 01:44
Hi. Did you ever release that update? I did allow beta 3 to update when it first ran.mr.bear wrote:UPDATE: Nicoman35/AldeberanPrime - I've fixed the issues you were having, they'll be included in the next update
I am having a similar issue: http://imgur.com/yOkleRC
However, I do not have a 0003* in my addon\t folder, and there is no 0123* file on my disk.
EDIT: From Console.rtf, I see:
Enumerating English language files
Reading language file: I:\X3AP-APCP\addon\t\0001-L044.pck...Success
Reading language file: I:\X3AP-APCP\addon\t\0002.pck...Success
Reading language file: I:\X3AP-APCP\addon\t\0003-L044.pck...Success
Reading language file: I:\X3AP-APCP\addon\t\0010-L044.pck...Success
Reading language file: I:\X3AP-APCP\addon\t\0123-L044.pck...Success
Reading language file: I:\X3AP-APCP\addon\t\0901-L044.pck...
So it appears that XS2 succeeded in reading files that do not exist , but it choked on the same 0901 reported previously by Nicoman.
- (Win8.1 x64)
Peace through superior firepower
Bullwinkle's List | Marine Repairs and Training | Mobile Mining Mk2 | Drone Carrier Software 2 (DCS2) | Ship Tricks: Mini-Guides (with Video)
Bullwinkle's List | Marine Repairs and Training | Mobile Mining Mk2 | Drone Carrier Software 2 (DCS2) | Ship Tricks: Mini-Guides (with Video)
Hello
0003* - contains dialog lines for exporting game stats.
0123* - contains dialog lines for DiD mode and are connected with Steam connection.
Q: 0901* - I read somewhere that is connected with plugin manager (I'm not using it because it erase my saves few times) - can I get it somewhere to look what text lines (page ID and text ID) it has I search for missing lines from pageID=35 (got few readtexts in my game).
Sorry Dr but you are wrong, 0123* and 0003* tfiles are hidden in 01.dat.DrBullwinkle wrote:(...)
However, I do not have a 0003* in my addon\t folder, and there is no 0123* file on my disk.
(...)]
0003* - contains dialog lines for exporting game stats.
0123* - contains dialog lines for DiD mode and are connected with Steam connection.
Q: 0901* - I read somewhere that is connected with plugin manager (I'm not using it because it erase my saves few times) - can I get it somewhere to look what text lines (page ID and text ID) it has I search for missing lines from pageID=35 (got few readtexts in my game).