Hard Light Productions Forums
Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: Inquisitor on October 05, 2002, 12:59:08 pm
-
RT is gonna take a crack at getting our build to work with the Demo VPs
If anyone has any suggestions, let us know here.
-
I think I may have bitten off more than I can chew.
There are 192 instances of the FS2_DEMO defines.
Some of them are comments, a lot of them are cutdowns of the engine, ie smaller maximums which should just be able to come straight out.
However the tricky bit where I am out of my depth is the tables.
The demo code did not compile as such, and any fix attempts cause a crash processing the medal table.
If theres any code history in fs2_open thats revelent to this I could do with knowing.
I will look into this more, but ultimately my time would be better spent continuing on the DX8 stuff if this drags on too much.
-
can we legally take the demo tables and modify them so it works?
-
I'd like to just get a version that works with the vanilla demo VP's that we can multi on and allow people to add custom content.
I guess it's time to document those 192 instances and check em all out :)
I agree RT, your time is probably better spent on the DX stuff, maybe one of the new guys?
-
Oh well, at least I got a look at some different code.
Like I say most the the demo code paths just take out graphical effects or detail. I guess maybe they wanted the demo to run nice and fast to keep everyone interested.
But I couldnt get to that code cos you have to deal with the table problems first. I doupt anyone will manage to get one exe that will run both FS2 full and demo data without some nasty command flag or changing the demo table data.
Tricky one, might be an idea to work closely with a MOD guy on this one.
-
You can almost cut and paste from our branch. Even the one that you guys have in your CVS does the demo. It's something like 10 lines of code to get the demo working.
Edit: Oh, you're trying to get demo and full version working in the same executable.... good luck.
-
well hell we don't even have know how to get FSO working for most mods, I think it would be better to figure out what things need to be fixed to get most mods working well.
-
I figured it would be worth looking into getting the demo to work with the same exe, failing that, make the demo exe able to do some more "retail" like things :)
-
Any chance of seeing those 10 lines of code? :)
-
Originally posted by RandomTiger
However the tricky bit where I am out of my depth is the tables.
The demo code did not compile as such, and any fix attempts cause a crash processing the medal table.
I think the one of medal names where exactly one charachter too long in the demo.
i recall Dave and the developers discussion this on that external community chat.
-
Yeah, that's the problem DTP, just need to actually go in and do something about it :)
-
The next problem is the weapons table.
Though please dig up that discussion if you can.
-
well, it was not a chat, but rather that section of Fs2.com called bugfixoftheday
anway here is the link
http://www.freespace2.com/bfod.cfm
and a quote from that
-----------
9.14.99
Item #: 4096
Original Date: 9/2/99
From: Jim Boone to Jim Boone
[Freespace 2] Dave, I'm not sure which programmer I should assign this to so I was hoping you could pass this to the relevant person. I set up and event to give the "Distinguished Inelligence Cross" for a loop mission and Fred crashed with the following error:
Jeff Farris: I got $10 that says this is the "no-room-for-null-terminator" wackiness that was discussed a while back.
Dave Baranec: This medal name is exactly one charcater too long.
Jim Boone: Well Jason, looks like we need a new name. Any ideas?
Jason Scott: Hm. Can we just call it "Intelligence Cross" in the table and "Distinguished Intelligence Cross" in the debriefing?
Dave Baranec: How about "Conspicuous Intelligence Cross" ? That fits.
Anoop Shekar: Yeah, but would you want an Intelligence Cross to be conspicuous?
Jason Scott: Let's just leave it Intelligence Cross. I don't want to touch the debriefing.
Jasen Whiteside: Good call. Make it so.
Jim Boone: Done.
And you thought putting medals into the game was simple!
-------
unquote
-
Originally posted by RandomTiger
The next problem is the weapons table.
Though please dig up that discussion if you can.
Did you correct the #define MAX_WEAPONS 100 in weapons.h
-
Dave Baranec: How about "Conspicuous Intelligence Cross" ? That fits.
Anoop Shekar: Yeah, but would you want an Intelligence Cross to be conspicuous?
:lol:
-
dave si teh funney
-
You probably already know this, but in case you don't, the game apparently verifies tables using checksums in a debug build and the checksums for demo 1 are commented out. It also looks like the demo's code split off from the FS2 tree. Whether it was ever merged back in or not, and exactly what changes were made, I don't know. (Comments in FreeSpace.cpp.)
-
Yeah, I have been diggin thru it to see what's up with that.
-
I believe the medal bug in Bugzilla is caused by differences in the demo's medals.tbl file.
required_string("$Wavefile Base:");
stuff_string(Badge_info[bi].voice_base, F_NAME, NULL, MAX_FILENAME_LEN);
//required_string("$Wavefile 2:");
//stuff_string(Badge_info[bi].wave2, F_NAME, NULL, MAX_FILENAME_LEN);
From the above code it looks like they replaced "$Wavefile 1:" with "$Wavefile Base:" for the release version. That bug's error message would be the error message thrown by required_string() when it can't find the string it needs. :)
(FYI, I'm posting this here 'cause I have no idea how I could add a comment to the Bugzilla one.)
-
I'd need to add your account to bugzilla as a developer :)
Wanna be a developer (been a while since i asked you :))?
-
That wouldn't do a whole lot of good right now as I can't even compile the source code anymore. :)
-
Email from WM from a while back on what files you need to get this working with the Babylon Project:
"List of files needed to play TBP's 1st mission with fs2_open (I seem to
remember a problem with the weapons/ship selection, though)
medals.tbl
weapon_expl.tbl
Multiingame-m.pcx
empulse.pcx
empulse2.pof
trebuchet.pcx
trebuchet.pof
***
exp05_1.ani
exp05_2.ani
exp05_3.ani
exp06_2.ani
exp06_3.ani
exp20_1.ani
exp20_2.ani
exp20_3.ani
-C
"
-
At the risk of restating the obvious:
The format for a few tbls have changed between demo and retail (weapons and medals seem to be the culprits, IIRC). I don't think table size has anything to do with it, since all of the demo tables are smaller than the retail ones, I would assume...
Can we modify the demo VPs if we can narrow down the differences? I don't know what the legal issue w/ distributing the demo files are, let alone "hacked" demo files...
Also, I think the checksumming thing is only for multiplayer, to make sure someone isn't using hacked tbl files. It shouldn't affect SP gameplay.
-
Yeah, but the reason this came back up was the iddulus.org people were able to use the demo build option to make it compatible, I thought we might do the same thing if nothing else :)
Maybe DTP's mod support can help us somehow...
-
Originally posted by Inquisitor
Yeah, but the reason this came back up was the iddulus.org people were able to use the demo build option to make it compatible, I thought we might do the same thing if nothing else :)
Maybe DTP's mod support can help us somehow...
indeed, I just managed to get it to read VP files from the mod directory.(first come, first served). a golden rule for vp files
There are still issues however, as it is right now it will look for this path in the VP file.
freespace2/modarguement/data/all-legal-sub-directories
and thats not good.
furthermore, if someone uses an incorret arguement(if the mod directory does not have the player directories or the mod directory do not exist then as it is right now, then, source will "bail".
i plan to make it so if not found, create does directories.
Actually,the mod directory and the subdirectires player/single(multi)(squad) Must exist or the source will bail.
and i plan to make it so, that if not found, create them, in the mod directory.
But i need to be carefull, since we are talking about writing stuff to the players Hard-disk now, but since we are "only" talking about creating subdirectories and not actual files, that risk should be minimum.
it still needs a bit tweaking, but rest asure it is a reality, mod support almost like in Half-life is going to be added to FS2-SCP
This will eliminate the multiple user errors like playing with same pilot in different mods.
It will also eliminate the mess that a mission directory sometimes can become.
And yes, using it for the demo files is ceartinly possible, but I need to test some things here however. but it should not look for what not referenced in the TBL files. as long as a complete set of tbl files is there in the demo.
i just tested it with the fs1port, and yuppie, all GFX files, POF files, ANI files that is in the fs1.vp where used instead of the originals.
Even the mainhall pcx, ani files(my own custom ones) are read from the mod directory.
Modding will just be so much easier now, when i get this completed.
---
and i almost forgot. The old way still works.
-
Anxiously awaiting this :)
You might want to committ work in progress, you know, in case soemthing happens :)
-
Originally posted by Inquisitor
Anxiously awaiting this :)
You might want to committ work in progress, you know, in case soemthing happens :)
Like what? He gets run over by a bus? Let him finish it first!
This doesnt mean freespace will work with the demo dtata only though does it?
Does it work by command line or can you switch in the campaign room with the same effect as well?
Either way, great work :)
-
Yes, something like that. Or a hard drive crash, or a virus, or a "oops, I didn't mean to save that!!" or a bad copy/paste that overwrites good files, or a family member/roomate accidentally deleting something, or... Oh, you get the picture :)
As a rule, I prefer more often committs.
That's the way CVS is supposed to be used. You don;t have to agree with the philosophy ;) But that is my preference and the thing that works the best in my years of software project experience. It backs the data up somewhere other than your PC, and it has the side benefit that other people can get a sneak peak :)