Jump to content
Rich Nagel

New C&C TD Command Line Parameter Discovered!

Recommended Posts

I don't think this is 'old hat' <G> as I've yet to read anything on the Internet refering to it.

 

One of the command line parameters in C&C's GAME.NEW and GAME.DAT files is "-ATTRACT". After looking around the 'Net, the only info that I could find on it was in a text file written by Nyerguds at http://nyerguds.arsaneus-design.com/cncstu...xt/ccparame.txt .

 

Other unknown command line parameters are "-0" and "-X", but I have no idea what they do. Also, I have no idea if these command line parameters (as well as the "-ATTRACT" one are contained in C&C95 (as I only have C&C for DOS v1.22), but they may be.

 

Anyhow, the "-ATTRACT" command line parameter starts C&C in a 'storefront' demo mode of sorts. After one minute of idle time at C&C's main menu, the game starts up map, and then begins to play C&C (complete with units/structures/infantry/etc...)! It looks just like if you were actually playing the game yourself, with units being selected, commanded, and with the map being scrolled accordingly.

 

I'm not sure what map it is, but it appears to be SCM01EA (the multiplayer map "Green Acres")... unfortunately after about 45 seconds of gameplay, C&C crashes back to DOS with the error message "pure virtual function called!" :(

 

I tried a fresh install on various PCs (including my old 486 native-DOS PC), but it always crashed after 45 seconds or so of the running demo... hence, I have no idea what would happen at the end of the mission (maybe it would start another map, and auto-play it as well?).

 

One interesting tidbit, everytime that I started it (before the 45 second crash), the demo appeared to be doing the exact same thing (same unit selections/move commands/map scrolling/etc...), appearing to be some sort of pre-recorded demo 'macro' of sorts... maybe some kind of an unfinished 'demo recorder' of sorts within the game.

 

Anyways, EXTREMELY cool looking! :) I just wish that it would continue without crashing. Like I said before, dunno if this is old hat (or if it's in C&C95), but I've never read anything on the 'Net refering to this.

 

(edit) P.S. Something gives me the hunch that the "Record.bin" file contained in the "TRANSIT.MIX" file is the recorded demo... and was recorded by a guy named "bill" <G>. Although the utility "VQAtoAVI 2" reports this file as being "info for map screens (population etc)", I think it might be the recorded demo that plays back.

Edited by Rich Nagel

Share this post


Link to post

I'd test, it but due to experimental hacks my C&C95.exe currently crashes on startup XD

 

I already found the info for the map screens in the exe file though, so that's definitely not what record.bin is.

Edited by Nyerguds

Share this post


Link to post
I'd test, it but due to experimental hacks my C&C95.exe currently crashes on startup XD

 

@All, Maybe somone else here with C&C95 could test this ("C&C95.EXE -ATTRACT" I'm assuming).

 

 

I already found the info for the map screens in the exe file though, so that's definitely not what record.bin is.

 

Thanks for the info, and you are correct, sir :) Hehe, I had just typed up the following message in Notepad, as was getting ready to post it here when I saw your reply <G>:

 

 

A small update: The "RECORDS.BIN" file (contained in the "TRANSIT.MIX" file) is indeed the file that contains the recorded/macro commands for the self-running demo.

 

Using a hex editor I chopped out all but the first 16kb or so of the file, and then started C&C with the "-ATTRACT" command line parameter. After 1 minute the demo started to play, but only lasted several seconds before returning to C&C's main menu... and didn't crash back to DOS like it did previously.

 

Just for a bit of random experimentation I created a blank map (using CCMap for Windows) and copied the resulting "SCM01EA.*" files to my C&C directory. The little bit that I could see before C&C crashed back to DOS was definately this new blank map (although C&C crashed much faster, as the blank map's layout is totally different that the usual "SCM01EA" map).

 

Lastly (just screwing around here), I renamed one of my savegames to "RECORD.BIN". After running C&C and sitting idle for 1 minute, C&C displayed the error message "Unable to read scenario!" (which I *knew* that it would <G>) - this text is in C&C's "LOCAL.MIX" file - but didn't crash to DOS... rather returning to C&C's main menu.

 

(edit) P.S.

 

BTW, I downloaded the C&C demo from ftp://ftp.westwood.com/pub/cc1/previews/demo - only the first file "cc1demo1.zip", as I'm on a measly dialup (the second file "cc1demo2.zip" is over 17 megs!) - and the files SCM01EA.INI/SCM01EA.BIN/RECORD.BIN are not contained in any of the ".MIX" files included in that ZIP of the demo.

 

I was thinking that maybe the self-running demo would actually work in the demo version (as this would be something that a computer store would run on an in-store demo PC years back), but unfortunately those files aren't included in the demo.

 

(To save me the trouble of downloading the larger of the two file "cc1demo2.zip") Does anyone know what files are included in this ZIP? Do any of the included MIXes contain the SCM01EA.INI/SCM01EA.BIN/RECORD.BIN files?

 

Edited by Rich Nagel

Share this post


Link to post

The second part of the demo are just optional media files, like movies and music. That's why they were put in a separate archive in the first place.

 

I know that Dune II has a self-playing demo like that... would be fun if the C&C demo included it too, but it doesn't look like it.

 

[edit]

 

In C&C95 it starts the demo and then crashes immediately... seems like it was never fully implemented in C&C95. Not to mention if the recording includes mouse movements, the screen is the wrong size for it to reach the build icons in the sidebar.

Edited by Nyerguds

Share this post


Link to post
The second part of the demo are just optional media files, like movies and music. That's why they were put in a separate archive in the first place.

 

That's what I figured, thanks for the info :)

 

 

In C&C95 it starts the game then crashes immediately... seems like it was never fully implemented in C&C95.

 

Thanks for the info. 'Tis a shame it doesn't work using C&C95 (or work fully in the DOS version), it's quite cool looking :) Well, for about 45 seconds or so, that is <G>.

Share this post


Link to post

Ya'know, for all the years i have been hacking these games, i have never tested -Attract :P

Share this post


Link to post
Ya'know, for all the years i have been hacking these games, i have never tested -Attract :P

 

Hehe, maybe we can also figure out "-0" (that's a 'zero') and "-X" :)

 

Man, I really wish that the "-ATTRACT" parameter didn't crash after 45 seconds... it's extremely cool looking seeing C&C 'playing with itself' <G>. Not to mention, the original "RECORD.BIN" file had to be originally 'recorded' in some manner... wonder if Westwood had some sort of 'in-house' demo recorder of sorts that they used to create the file with :)

 

(re: 'storefront demo') I wonder if there were any other demo/preview versions of C&C released, maybe one that this _actually_ would work without crashing. <AFAIK> the only demo version was v1.0a, dunno anything about the 'beta' version though.

 

Edited by Rich Nagel

Share this post


Link to post

Hey guys, I tried it out on my computer with TFD installed.

It kept requesting a disk, and only worked once i dug out my old C&C95 CD (GDI) and then the game booted up, but just sat there.

I then clicked multiplayer and the game Froze.

I can do some other tests if you want them, but I'm no good with this hacking ****, hurts my brain.

Share this post


Link to post
Hey guys, I tried it out on my computer with TFD installed. It kept requesting a disk, and only worked once i dug out my old C&C95 CD (GDI) and then the game booted up, but just sat there.

 

You were using the "-ATTRACT" parameter (just wondering, as we were also discussing the other unknowns, "-0" and "-X"), correct? If so, did you wait a full 60 seconds at the main menu (it takes that long in the DOS version for the self-running demo to kick in)?

 

Hehe, I've really been screwing around with this one for the past couple of days, and started using a digital cooking timer... so's I would have something to look at other than the main menu of the game before it kicked in <BG>.

 

 

I then clicked multiplayer and the game Froze.

 

That's strange. In the DOS version, the only thing that caused the game to crash was after 45 seconds of the self-running demo.

 

 

(O.T. ramble) Man, I really wish there was some way to hack/enable a 'skirmish' mode for C&C1, using the 'computer AI Players' during a multiplayer game :) Maybe if there was some way to fool the game into thinking there was actually two human players during a network game, but I dunno.

 

P.S. The recorded demo in question looks like there are computer AI players in it, as I see some of the AI taunts, e.g. "Beat me and I'll reboot!" etc..., at the top of the screen before the game crashes <G>.

Edited by Rich Nagel

Share this post


Link to post

Heh, you need to get C&C95 and have a nice chat with Nyer, he already made skirmish :P

Share this post


Link to post

Hm... not sure how easy it'd be to recreate that on DOS. I'd first have to identify quite a lot of things for that. Well unless it's enough to just completely remove the "# of players" check. That just causes you to win right away when no other (either AI or human) players are present :P

Also, CTF with AI players would still not be possible... I really can't be arsed to re-do the entire game mode hack (changing Bases On/Off to include CTF and Mobile HQ modes, so these last 2 can be combined with the AI Players option)

 

it'd be loads simpler if you just bought TFD though. Here's what you're missing so far:

http://nyerguds.arsaneus-design.com/cnc95u...html#changelist

with more coming pretty soon:

http://forums.commandandconquer.com/jforum...t/501.page#5421

 

Hey guys, I tried it out on my computer with TFD installed.

It kept requesting a disk, and only worked once i dug out my old C&C95 CD (GDI)

Obviously. TFD itself starts the game with the -cdCOVERT parameter to make the game play off your hard disk (though just a dot (.) instead of the "COVERT" works fine). If you want to test something like this you need to add BOTH parameters.

Edited by Nyerguds

Share this post


Link to post

Yeah i was doing the -attract thing

 

So i need "C&C95.exe -cdcovert -attract"?

And will i need the disk inserted?

 

EDIT:

I tried the above, and still needed the disk.

I got the same effect, no demo after 60 seconds, but this time no freeze.

Also none of the extra missions or skirmish options were available.

PS i have Nyerguds' patches installed.

Edited by BioBen

Share this post


Link to post
Hm... not sure how easy it'd be to recreate that on DOS. I'd first have to identify quite a lot of things for that. Well unless it's enough to just completely remove the "# of players" check. That just causes you to win right away when no other (either AI or human) players are present :P

 

I think that simply removing the number of players check would prolly do the trick :) Don't spend any additional time or work with it, but do you already know or have documented what the hex offsets and values should be for the GAME.NEW file?

 

 

Also, CTF with AI players would still not be possible

 

Understood, I kinda figured on that.

 

 

 

Man! That's a lot of great modifications! :)

 

Share this post


Link to post
Yeah i was doing the -attract thing

 

So i need "C&C95.exe -cdcovert -attract"?

And will i need the disk inserted?

 

EDIT:

I tried the above, and still needed the disk.

I got the same effect, no demo after 60 seconds, but this time no freeze.

Also none of the extra missions or skirmish options were available.

PS i have Nyerguds' patches installed.

Huh odd.. you should need

"C&C95.exe" -cd. -ATTRACT

 

How are you starting this?

 

The easiest way is to make a shortcut to C&C95.exe and adding the parameters in its properties...

post-1376-1227076179_thumb.png

 

What do you mean with 'skirmish options' though? C&C95 has no skirmish options; Skirmish is simply LAN with AI players enabled and without human players

Edited by Nyerguds

Share this post


Link to post
What do you mean with 'skirmish options' though? C&C95 has no skirmish options; Skirmish is simply LAN with AI players enabled and without human players

 

Yep, that's exactly what I mean. The ability to start a LAN game with only one human player, and having the game place AI players on the map :)

 

Share this post


Link to post

Sorry about the confusion, i just meant the option to play skirmish.

Share this post


Link to post

Bioben: again... C&C95 never HAD any skirmish option, and my patch doesn't add that either. It just allows LAN games to start without human players if AI players are used instead

 

Rich Nagel: I was talking about BioBen's post.

 

This hack removes the number of players check in DOS C&C v1.22:

89ABA: 75 EB

 

You'll have to enable IPX in DOSBox to get the Network option though.

post-1376-1227141942_thumb.png

Edited by Nyerguds

Share this post


Link to post
This hack removes the number of players check in DOS C&C v1.22:

89ABA: 75 EB

 

YOU DA MAN, Nyerguds!!! It works perfectly, wooohoo!!! :) This is exactly what I was looking for :)

 

 

You'll have to enable IPX in DOSBox to get the Network option though.

 

Actually, I'm not running DOSBox on any of my old boat-anchor PCs <G>, but rather use some old 'dummy' DOS IPX drivers "NE2000.COM" and "IPX.COM"... works like a champ :)

 

 

P.S. Hehe, man... those AI players can be quite insulting with thier rude taunts <LOL>!

 

Share this post


Link to post

"Beat me and I'll reboot!"

"YOU're artificial intelligence!"

:P

Share this post


Link to post

Man, I'm having a ball with this! :)

 

Hehe, took some of the stock missions (campaign, as well as Covert), did a little INI editing, renamed to SCM??EA.*, and let 'er rip <LOL>! :)

 

Share this post


Link to post

Nyerguds, I don't suppose that you would know of an offset in the GAME.NEW file that controls the number of AI players (maybe a byte that could be hex-edited to preset the number of AI players to 1, 2, or 3)?

Share this post


Link to post

Hmm... even if I can't find that, I know the one set by enabling the Players option... That's on 9647A. Should be "06" originally

 

 

[edit]

 

Ah, the original is at 12CCF8 11CCF8. That place is full of MP settings. Each is 4 bytes long. They should be:

 

NumberOfPlayers

UnitCountDefault

AddedUnits_Bases (set to 1. This is added to the number of units if bases are enabled, so the MCV doesn't count in the units slider. This means that the internal value is still "1" if the slider is "0", so the MCV still appears)

AddedUnits_noBases

MaxUnits_NoBases

MaxUnits_Bases

Edited by Nyerguds

Share this post


Link to post
Hmm... even if I can't find that, I know the one set by enabling the Players option... That's on 9647A. Should be "06" originally

 

Many thanks for the info! :)

 

 

Ah, the original is at 12CCF8. That place is full of MP settings.

 

I'm a bit confused... my GAME.NEW file (DOS v1.22) is 1,215,025 bytes in filesize, meaning that the last hex offset of the file is 128A30 (?).

 

Share this post


Link to post

ah sorry... I copied the address value from my disassembler. The actual offset 11CCF8

Share this post


Link to post
ah sorry... I copied the address value from my disassembler. The actual offset 11CCF8

 

Gotcha! Many thanks!! :)

 

Lot's of things to play around with now <G> :)

 

Share this post


Link to post

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

  • Recently Browsing   0 members

    No registered users viewing this page.

×