Jump to content

S2 Constants-Modding


Darth Valium

Recommended Posts

Hello you guys down under,

 

this is my 1st thread, and the first in english after quite some time, so be prepared ;-).

 

as you know, you have to install the ms-sqlserver to have access to the editing features, and of cause to the game's constants. to gain access to these, you have to create an "odbc-data source" with your win xp/2k, just look for "Data-Sources (ODBC), its somewhere in the systems-settings (in the same place with "computer-management"). its quite self-explanatory, just keep an eye for the "change the default database to:"-option, check it an choose "a5game" in the rolldown.

 

if you ve suceeded (there is a test option in the last dialogue), you just have to start your ms-access to gain, nomen est omen, access:

 

file->open->the choose "file-type" "odbc-databases"->in the next one click "computer data-sources" & choose the further created one.

in the next dialogue "select all", then okay. after this you have to click sometimes okay, after a while you will see the complete lists of dbs.

 

to understand the schematics, you will have to know, that some of these tables are just composed out of others, for example

"dbo_ammosort" or "dbo_weapons".

 

so lets do some basic modding, just for understanding-purpose:

 

at first, launch your console and move to your SStorm dir, subdir "tools".

 

there are 4 tools, the one we like at the moment is "dataimport.exe", which you will need to create the "game.db", which includes the changed constants.

 

okay, here is the should work on all machines command-line (keep in mind, that you have to type this in your command-prompt!):

 

"dataimport original.db -dbserver 127.0.0.1 -database a5game" (without quotas, of course).

 

after some seconds, you will have a file named "original.db" in your tools-folder, this thing is important, because its the export of the original, unmodded db, you will need it later.

 

now switch back to access, just for fun we will tweak the good old sea devil, give it an average range and really good damage.

 

to understand wepaons damage, two things are important:

a) the ammo type, which delieveres the basics damages

B) the weapons modificator to min/max damage

 

 

so, take a look into the table "dbo_rpgammos", its really easy to understand. at position 43 you will find the entry, an in the 8th & 9th row the corresponding damage. just change it as you like and close the window. after this, open "dbo_rpgweapons", and scroll down to position/id 142, "sea devil". change the position 11 &12 (column) as you like, to tweak the range.

by the way, column 9&10 represent the weapons modificator of the use ammo-type, but its more important for ammunition, which is used by several guns. now close the windows'. before we can export the settings, we have to update de db, to do so, you must right-click on one of the tables, an the left-click the last menu-entry, something like "tableconnection-manager". there choose "select everything", then okay, after some seconds all corresponding tables have been altered.

 

now you can close access, and change to the command-prompt window.

 

you have to type the following with the following command-line:

 

"dataimport full-mod.db -dbserver 127.0.0.1 -database a5game"

 

after some secs you have a ~38Mb file, which is an import of the now modded database. basically you can rename this file and use it as a mod, but its not the stylish way, we are only interested in the things which really changed, so we we have to run another command-line:

 

"dataimport game.db -diff full_mod.db original.db"

 

after this, we have a small file, named "game.db" in the tools dir, which is our mod. now create a subfolder beneath your s2-main-dir, example "testmod", copy the new "game.db" to this place, and create a txt.-file in this dir, called "description.txt", in it a short explanation of the mood (a few words).

 

now start your silent storm (by the way, you can speed it up when you edit "sstormcfgintro.seq" and remove everything except "exec mainmenu") and run a new campagne. then spawn a sea devil with "getitem 382".

 

----

 

if it hasnt worked, no problem, after this you should have a basic idea how modding the ss-'s constants works!

Link to comment
Share on other sites

Wow, that is an excellent first post!

 

Thanks very much for the detailed tutorial, I am sure a lot of people will find that very useful.

 

I'd liek to have a bunch of Editor tutorials on the website, if you don't mind I may at some stage use what you have written. it will be a little while yet, I am still waiting to get my english copy.

Link to comment
Share on other sites

Hey Darth Valium. Great post, and I'm sure it'll be incredibly useful to a lot of people.

 

I'm having some trouble getting the ODBC thing set up properly. I went to ControlPanel->DataSources(ODBC), but couldn't find a "change default database" rollout. Am I looking in the right place? Is there another ODBC configuration window somewhere else?

 

I really can't wait to start messing around with this. :)

Link to comment
Share on other sites

okay, i explain it:

 

1. launch the Control panel / Datasources (ODBC)

2. under the tab "User-DNS",it is normally the default one, click on "add"

3. the next windows is something like "create new datasource", there scroll down to "sql-server", then "finish"

4. in thew upcoming dialogue type in the name & perhaps a brief description, then choos your host under the section "server", and next

5. in the next window "create a new data source to sql server" everything is fine,just hit next

6. this is the windows, "same name as above", where you have to check the upper check box ("Change default....."), and select your database. there will be several, the main database is A5GAME, if you created a new instance (whene the editor starts, you are aksed if you wish), it is named "A5GAMEMOD_thenameyouchoose". here s a tip, create a new database before editing around, so you always have the orginal untouched. okay, checked and selected? then next

7. in the last one just hit "finish", congrats, youve just created a new datasource and can load it in your access

 

information for german users:

---------------------

ich habe im jowood-forum auch einen thread hierzu laufen.

https://forum.jowood.de/showthread.php?s=&t...&threadid=52475,

dort bin ich allerdings "Darh Bier"!

Link to comment
Share on other sites

"4. in thew upcoming dialogue type in the name & perhaps a brief description, then choos your host under the section "server", and next"

 

Well.... i have a problem here, i dont have any "host" in the rollout.... when i click on next, i have an error message "connection failed" something like that...

whats wrong?

 

Edit : Ok i had to uncheck the "test connection" in the 3rd window.

But i cant select the A5GAME thing.. you see? I have a rollup and nothing inside... is there a problem or you must type "A5GAME" ?

Link to comment
Share on other sites

Yes it starts......

In fact i cant understand the link between windows ODBC settings and silent storm editor?

Well.... i just re-installed the game, the editor, and the SQL thing of the CD, and i still dont have this "A5GAME" in the list....

Dont you have to select the Silent Storm repertory before, or something like that? How does the computer knows it is connected with silent storm?

Link to comment
Share on other sites

delievered with your s2 is the database, which hasnt a connection to the game itself. the game has it's own format, the *.db's. while you are editing resources, your are not doing this with runtime-files of the game or the *.db's.

 

there is no link between odbc-settings and s2-edit. the routines for accessing the sql server are hardcoded into the s2-editor's executables, the odbc data-sources have to be created to gain access to the data from a generic db-client, like ms access for ex..

 

a lot of values can be altered trough the editor, so perhaps you dont need to fumble around with the odbc settings.

 

there are a lot of possiblities, why this wont work for you, and solving this can be really hard, because this "trial" of the real ms sql server is really hard to manage.

 

not sure what your mean with repertory; there is regular only one instance of ms sql-server running(@home-user-pc's), and below this instance of the sql-server are the databases, some db's for the databasemanagmentsystem. some for the "normal" databases.

"a5game" for example is one of the databases, which should be available in this list. if there is no entry, there must be a problem accessing the server, or perhaps you have chosen wrong before.

 

----

 

i should have typed: "there is regulary no instance ...."

Link to comment
Share on other sites

Well I just couldn't choose any server, i had no servers in the list...

But i managed to make my mod, in fact the first time i tried i forgot to create a new database, and the SQL server was not running.

So now it works perfectly :wink:

 

Thanks for your help 8)

 

 

Edit : wow i just managed to make the OBDC thing works! in fact i had to type the name of my server (the name of the server indicated in the MySQL server, well the thing you install with S2)

Woohoo!

Link to comment
Share on other sites

  • 2 weeks later...

OK, I've gone through the entire procedure, but whenever I try to change data in any field I am told it is being edited by another user! It wont let me make ANY changes to the database.

 

It has 3 options, Save Change, Copy Change & Drop Change BUT Save Change is permanently greyed out.

Link to comment
Share on other sites

Hello,

 

I'm not sure what all this stuff above is talking about. I was getting an error saying that I didn't have mssqlserver service running. I am using Win XP. Here are the steps I used to get the editor running, it's rather simple.

 

1. Install Silent Storm with the Editor

2. Put in CD 1 if it is not already there.

3. Browse the cd

4. Open the bin directory

5. Open the MSDE directory

6. Run setup.exe

7. After it is finished installing run the mapedit.exe from your Silent Storm directory.

 

Hope this helps someone.

Link to comment
Share on other sites

Cheers, nice to have it in concise steps :(

 

but what is being discussed in this thread is editing the databse tables that can't be accessed through the game editor.

 

I've just found a program to do the job though, someone had actually posted a link in another thread, and it worked MUCH better than access.

 

BlueShell Dataguy is the program.

 

https://www.blueshell.com/EbDg.asp

 

that's the link.

Link to comment
Share on other sites

choose file -> new -> OLE DB connection

then choose -> Microsoft OLE DB Provider for SQL server

In the same window in DataLinkProperties:

1. in connection, under servername type or copy the name of the SQL server running on your taskbar (double click the icon and you'll see the server name - mine is XP1900 .. something)

2. choose: use integrated NT-security (mine is in dutch so sorry if it's not identical)

3. under three you should now get the dropdown menu of all databases

you should use the one named A5GAMEMOD_(your mod)

 

This works under XP, I pieced it together from other posts when i faced the same problem, thanks to those guys :wink:

PS: i'm waiting for the 1.2 patch (see other threads) before changing these values, because now they get all screwed up

Link to comment
Share on other sites

in dataGuy: just hover your mouse pointer over the left (grey) edge of any of the tables and you'll see: ... push to save

 

after you made the changes in the database, re-enter the editor and "build" the mod again,

the changes you made in the database will now be in your mod.

(there may be a faster way to do this, i'm not sure)

 

hope this helps :wink: [/img]

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...