learning xml - scripting

The place to discuss scripting and game modifications for X²: The Threat.

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

simduck
Posts: 103
Joined: Wed, 6. Nov 02, 20:31
x3

learning xml - scripting

Post by simduck »

I am very eager to learn how to create scripts and am needing some help.

I have a basic knowledge of VB6 and I have been opening up other's scripts to try to understand the language.

Is there or has someone got some basic documentation that I can mull over to help me practise making my own scripts?

Thanks 4 ur help.
One must die to self to live for self.
User avatar
giskard
Posts: 5230
Joined: Wed, 6. Nov 02, 20:31
xr

Post by giskard »

IF you want to see the persons script and its already unpacked eg not a pck file anymore i suggest you either load it into the game and view it using the script editor or do as i do and do a search replace for < Text > < / Text> < var> < / var> and that %#160 thing so it replaced them with either spaces or nothing. Then you can examing the script more easily outside the game.

Im sure there are some experts around here that can offer a better altenative than that.

The benefit of stripping away the xml from scripts is you get to see the code you would see in the game but without loading the game. Which is handy if your examining several scripts to see how certain commands are used.

Except for the english part of the scripts, eg the 40003.xml style files, most of the xml for the other files appears to be formating info generated by the game when you use the in game editor.

I could be wrong though, perhaps somebody could confirm this who knows more than i do ?

Giskard
This signature has been stolen by the well known Teladi Signature Thief X Siggy.
Nemesi$
Posts: 120
Joined: Wed, 12. Nov 03, 19:05
x4

Post by Nemesi$ »

For simple viewing of the xmls just doubleklick them. Now you can view them very nice formatted in your browser (e.g. IE) Thats what the xls is for.
Die Zehn Gebote haben 279 Wörter, die amerikanische Unabhängigkeitserklärung hat 300 Wörter. Die EU-Verordnung zur Einfuhr von Karamelbonbons hat 25911 Wörter. [Bodo H. Hauser]
User avatar
Jimmy Jazz
Posts: 794
Joined: Wed, 4. Jun 03, 17:20
x3

Post by Jimmy Jazz »

@Nemesi$: I just love your signature

:lol:
User avatar
giskard
Posts: 5230
Joined: Wed, 6. Nov 02, 20:31
xr

Post by giskard »

All i get is a black page with mosty scripts nemesis, that was the first think i tried. Mind you i used dreamweaver so perhaps a browser would work better :)

Giskard
This signature has been stolen by the well known Teladi Signature Thief X Siggy.
Nemesi$
Posts: 120
Joined: Wed, 12. Nov 03, 19:05
x4

Post by Nemesi$ »

Just open the xmls with your InternetExplorer. It's displaying them correctly. I have version 6SP1 of it installed (WinXP with SP1). Although I browse with Opera thru the net, I use IE for the xmls since Opera is displaying some weird stuff without any format.

You just have to make sure the x2script.xsl resides in the same path as the xmls. x2script.xsl is the stylesheet.
Die Zehn Gebote haben 279 Wörter, die amerikanische Unabhängigkeitserklärung hat 300 Wörter. Die EU-Verordnung zur Einfuhr von Karamelbonbons hat 25911 Wörter. [Bodo H. Hauser]
User avatar
giskard
Posts: 5230
Joined: Wed, 6. Nov 02, 20:31
xr

Post by giskard »

Nemesi$: Thanks mate, it works fine now.

My system is setup to load xml files in for editing due to my freelancer mods using xml too. I never considered Internet explorer.

Giskard
simduck
Posts: 103
Joined: Wed, 6. Nov 02, 20:31
x3

Post by simduck »

Thanks all for ur help. Greatly appreciated. I have followd Reven's excellent advice and now understand the basics.

THANKS
One must die to self to live for self.

Return to “X²: The Threat - Scripts and Modding”