You are currently viewing our boards as a guest, which gives you limited access to view most discussions and access our other features. By joining our free community, you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content, and access many other special features. Registration is fast, simple, and absolutely free, so please, join our community today!
The utilities in this topic are my own, and are not made or necessarily supported by "Spock" or other players in the BZ community. Use at your own risk. Do not use this to test 1.5 for Ken. He isn't involved with this project, nor is Christian Leinen. None of Leinen's source code was used, I built this from scratch using Game Maker, and he probably doesn't even know this program exists.
Project was started in Game Maker 6.1, then ported to Game Maker 7.0 for Vista compatibility, then back-ported to version 5.3 for Windows 98 compatibility, then I decided to ditch Windows 98 compatibility as it was too much hassle, and I ported it to version 8.0 to compile it with an icon that had multiple sizes.
Presenting: *Theme from 2001: A Space Odyssey plays*
Main Screen NSDF Campaign CCA Campaign Black Dog Campaign Chinese Campaign IA Missions
Changelog:
Spoiler:
Code:
BzConfig for 1.5 v1.0: * Dropped support for RO * Dropped support for 1.4 * Removed CD music feature * Removed Restore Cursors Button - Cursors are still restored on exit * Removed Utility Close-on-launch option * Moved close button to the bottom * Removed obsolete settings - ZBuffer - SplitZbuffer - HiRes * Added new rendering settings - Buffer32 - Texture16 - Vsync - MultiSampleType - MultiSampleQuality - MaxAnisotropy - HardwareClip * Fixed a few errors that I never found before * Improved Error handling * Improved Map Selection - You can now click on the list to pick a map - Creating a new map rebuilds the list (new map shows up right away) instead of launching the editor. - Added flags * Fixed button text rendering problem that some experienced. (Non-integer x/y text position) * Improved program behavior in the event that it cannot find Battlezone - You will be prompted to browse for the executable - Moved executable file name from hard-coded constant to config.ini - Various checks to make sure the user didn't just pick anything, and didn't accidentally choose 1.4 installation * Single Instance Application * Fixed launch not working if utility is on a different drive than Battlezone - Eliminated batch file usage - Wrote a DLL in C++ implementing ShellExecute() to launch Battlezone/Red Odyssey * Windows NT or later and a graphics card is required, I will not support Windows 98 anymore.
BZ/RO Config (For Battlezone 1998) v3.1: * Updated the old BZ/RO utility with various code improvements from the new utility and included it. * Switched "From Out of Nowhere" and "Rescue Me" (they are switched in the game)
New in v3.0: - New Map button. Create a new blank map without the command prompt! Read the IA map tutorial first before you use this, even if you aren't making an IA map, but a DM or strat map. - Found Leinen's current site, re-added to links in About box. - Restore Mouse Cursors button. (Finally, thanks to leinensoft.com) - Mouse Cursors restored automatically on utility exit. - Fixed render.cfg logic. Instead of immediately reading render in utility's folder, it first gets a fresh copy from BZ folder. - Re-check registry upon failure to find BZ/RO. (An error you will likley never see) - Red Odyssey folder is now obtained from the registry, instead of assumed to be in same folder as BZ. (Assumptions are bad) - Fixed compatibility build not deleting temp folder. - The Utility is now pretty much complete! Thanks to all who test this and/or enjoy the convenience of a BZ/RO launcher all-in-one!
There will likely be another release when 1.5 patch is complete, with new render options for 1.5.
Settings/buttons made obsolete in BZ by latest 1.5 experimental build: - Zbuffer - SplitZbuffer - Restore Mouse Cursors Settings that might become obsolete in the 1.5 patch: - Enable 3D Card - Music from CD (music will hopefully be in the game directory)
New in v2.4 - 2.3 had an unknown variable error, fixed it. (Thanks Zachtank) - Added Hidden Evolve Level (The Red Odyssey) to the map launcher. - CD music ON/OFF option (CD music is mostly a novelty feature, it's for music in utility, doesn't effect game) - Remade the code to read instant_action.txt, and program now lists them alphabetically regardless of what order they are in the file. File structure is changed, each mission gets 1 line now:
<Name>|<Map File>|<Faction>
The program no longer generates the file, it is simply included in the zip archive. - Batch file is no longer deleted, but is re-used. This was done for purposes of speed. - Removed "@echo off" and "exit" from batch code, found it wasn't needed, CMD window disappears just fine without "exit" and "@echo off" really served no purpose since the window disappears.
New in v2.3: - strings.txt, rough equivalent of label.map in BZ/TRO.
Allows BZ Config 9000 to potentially be translated into other languages by somebody other than yours truly, who only knows English, and knows that Google isn't the best translator.
Unlike other editable files for this program, strings.txt is not generated by the code like render.cfg, config.ini, and instant_action.txt and is completely optional. In other words, if you delete it, it will not re-appear. It doesn't have to exist if you like the utility in English.
New in v2.2: - BZ and RO CD Music plays in application if CD is in. - Leinen's site link removed as it seems to be offline.
New in v2.1: - Fixed bug of file not existing because of bad file date. Machoman IA mission wasn't added as IA mission on level select screen because the utility checks if the BZN files exists in addon. I wrote my own file_exist script which won't fail like GM's built-in file_exists function. - Utility now reads netmis.txt and adds multiplayer maps to the list after the IA missions. They were already in the list before, but now for example instead of just "multdm99" you see "Deathmatch: Coliseum".
New in v2.0: - Level selection feature added, can load BZ and RO SP missions, BZ IA missions, and has a map editor checkbox for editing maps. - 3D Card checkbox added for troubleshooting purposes. - Utility Fullscreen/Window button added. - BZ and RO paths are now in config.ini, no more bzpaths.ini. - Fixed batch code, CMD window wasn't always disappearing. - Added editable text file, instant_action.txt. It stores a list of IA Maps, so they can be played via the Level Selection screen. The format of this file is as follows:
<Map Title>|<Map Filename>|<Faction>
Map Title: the map's name, e.g. Ice Ice Baby Map Filename: the map file, e.g. iceiceba.bzn Faction: Who you play as, e.g. NSDF. This is displayed on the map selection screen as a Main Battle Tank graphic and text description. NSDF, BDOG, and CCA are the 3 possible factions.
All of the IA missions that come with the community's Battlezone 1998 Installer are already in the list.
If you didn't choose to install the IA missions when you installed Battlezone 1998, they won't show up, because the utility checks if they are installed.
Features: - Enhanced GUI (Looks like Battlezone) - Sound Effects (Sounds like Battlezone) - Utility works for both Activision's Battlezone and Team Evolve's Red Odyssey Expansion. - Saves local program settings in config.ini - Has most of the features of the original utility by Christian Leinen - Utility doesn't have to be in BZ directory. - On first run, utility will read BZ path from registry. - Uses batch files, but deletes them after use and CMD window only exists for a fraction of a second (almost completely transparent for user) - Links to http://www.battlezone1.net and http://www.leinen.com in About box (credit given to Christian Leinen for original utility's design, as without it, this program probably wouldn't have been made) - Similar layout to Leinen's Utility
See you in the zone!
- Sporkinator
To do list: NOTHING, other than maybe alphabetize the MP map list.
This program is fully tested to work on any proper Battlezone and The Red Odyssey Installations made by the Battlezone Community at battlezone1.net. If you are using an old BZ/RO installer from somewhere else and/or a version prior to BZ 1.4 / RO 1.3, I take no responsibility for any error messages you may see, or any problems you may encounter.
As far as I know, everything works 100%. If you find a bug or a glitch or encounter a strange error message, take a screen shot and show me the error/bug/glitch via PM. If you can, tell me how to reproduce the error/bug/glitch, that will be important for quickly finding the problem in my code and fixing it.
Thanks in advance.
Last edited by Sporkinator on March 2nd, 2010, 4:58 pm, edited 22 times in total.
Joined: August 20th, 2007, 12:17 pm Posts: 3133 Location: Zagreb, Croatia
Sporkinator wrote:
The Utility now works with The Red Odyssey as well as regular BattleZone. It checks for bzone.exe and if it didn't find BZ, it then checks for odyssey.exe. I don't know how odyssey14.exe is different than odyssey.exe, (other than file size difference) so if you know what it's for, let me know, as my utility currently doesn't check for odyssey14.exe.
Odyssey.exe starts RO in RO lobby, odyssey14.exe in Bz 1.4 lobby. For Config Utility it makes no difference.
Sporkinator wrote:
- Can have multiple BattleZone installs, like L, M, N, RO, and be able to configure all 4 of them individually. (place copy of utility in each directory, and create shortcuts to each on desktop if you wish)
Would be better to have 1 Utility changing both Bz and RO render in the same time. Can you do that?
Hmm... that's a good idea, not sure if it will be easy, as it currently modifies render in the directory it's in, and I made the title bar change to say "Red Odyssey Configuration Utility" if it finds RO instead of BZ.
I could have it store the path to BZ in a file along with path to RO, then the utility can exist in its own folder, and modify BZ and RO render. I could make it have 2 start buttons: "Start BZ" and "Start RO". The file, for example could be named bzpaths.ini.
Its structure would look something like this:
Code:
[Paths] BZ=C:\Program Files\Activision\Battlezone\ RO=C:\Program Files\Activision\The Red Odyssey\
and I could make title bar say "BattleZone/Red Odyssey Configuration Utility".
Which Red Odyssey executable is launched does matter for configuration utility if people want to play online in Red Odyssey. If it launches odyssey.exe instead of odyssey14.exe, it will run in seperate session from BZ 1.4. I can easily change which one it launches, or check for both, launching odyssey.exe if odyssey14.exe is not found.
Who made the server session patch for RO? Activision? If not Activision, that means somebody else has RO code, and we could get NO CD patch for RO. *crosses fingers, wishful thinking*
EDIT: I have run into a strange problem that only occurs if I have my utility launch BZ or RO using a path. BZ or RO will launch, and then crash claiming that it could not find required files to run. I do not understand why this is happening. It saves render.cfg in its folder, copies the render.cfg to the BZ/RO directories, then launches BZ or RO. I even had my program show debug messages before launching, telling me the exact path it was launching. It was correct.
Looks like the BZ+RO Utility both-in-one can't be a reality unless I find a way to fix this (I don't even know what's wrong).
It works just fine when the utility is in the same folder as BattleZone and launches it locally.
*pulls hair out* I don't know why it won't work!
It somehow causes BZ or RO to look somewhere else for required files when utility is not in the same directory as the game.
The launch is successful, but then the games complain about not finding files.
If anybody has a theory on why this happens, let me know.
For now, I will switch it back to local code, since that works great. The same utility can be used to configure both BZ and RO, but currently a copy of the utility is required in both the BZ folder and the RO folder, and you have to launch from BZ to configure BZ and launch from RO to configure RO.
EDIT 2: I found that it works if I first create a batch file, then run it. Still experimenting to see what I can do with batch files. Trying to see if there's a way to silently execute DOS commands without showing the window or make it disappear after it executes bzone.exe, odyssey.exe, or odyssey14.exe.
EDIT 3: It works great with batch files! It's now a reality! BZ/RO Config both-in-one utility.
Found a Process Viewer DLL which I utilized to find out if BattleZone or Red Odyssey is already running before attempting to launch.
Even though execution based on "bzpaths.ini" is working now, it is possible to change the "UsePaths" setting in "config.cfg" and have the utility do the local check, running in directory of installed game and checking for the game there, in which case it will check for BZ, and if BZ is not found, will check for RO14, and if RO14 not found, will check for RO, and if that's not found, will alert the user that nothing was found.
Does the installer write an entry for the location of BZ and an entry for RO in the registry? That'd be nice, because then my utility could get 2 default directory paths from the registry when creating bzpaths.ini for the first time.
I'd have to know how to do that though, as I've never used the registry functions that I have available to me:
Quote:
Registry If you want to store a small amount of information between runs of the game there is a simpler mechanism than using a file. You can use the registry. The registry is a large database that Windows maintains to keep track of all sorts of settings for programs. An entry has a name, and a value. You can use both string and real values. The following functions exist:
registry_write_string(name,str) Creates an entry in the registry with the given name and string value. registry_write_real(name,x) Creates an entry in the registry with the given name and real value. registry_read_string(name) Returns the string that the given name holds. (The name must exist. Otherwise an empty string is returned.) registry_read_real(name) Returns the real value that the given name holds. (The name must exist. Otherwise the number 0 is returned.) registry_exists(name) Returns whether the given name exists. Actually, values in the registry are grouped into keys. The above routines all work on values within the key that is especially created for your game. Your program can use this to obtain certain information about the system the game is running on. You can also read values in other keys. You can write them also but be very careful. YOU CAN EASILY DESTROY YOUR SYSTEM this way. (Write is not allowed in secure mode.) Note that keys are again placed in groups. The following routines default work on the group HKEY_CURRENT_USER. But you can change the root group. So, for example, if you want to find out the current temp dir, use
registry_write_string_ext(key,name,str) Creates an entry in the key in the registry with the given name and string value. registry_write_real_ext(key,name,x) Creates an entry in the key in the registry with the given name and real value. registry_read_string_ext(key,name) Returns the string that the given name in the indicated key holds. (The name must exist. Otherwise an empty string is returned.) registry_read_real_ext(key,name) Returns the real value that the given name in the indicated key holds. (The name must exist. Otherwise the number 0 is returned.) registry_exists_ext(key,name) Returns whether the given name exists in the given key. registry_set_root(root) Sets the root for the other routines. Use the following values:
I know you probably aren't a programmer, but this shouldn't be too hard if you know the registry.
Maybe you can suggest which function I might use, and what parameters I might pass to it to obtain a result. I've been experimenting, and all I ever get is an empty string, meaning nothing was found. I ran regedit and found BZ in the registry, but I'm trying to figure out, for example, how to retrieve the value of AppPath using the registry functions: Well, in the meantime, I'll keep trying until my function returns that string.
YET ANOTHER EDIT: I took my issue to the Game Maker Community Forum, and in the end I was missing something obvious. A user pointed out my obvious mistake, and provided working test code:
Code:
registry_set_root(1); //HKEY_LOCAL_MACHINE var value; value = registry_read_string_ext("\SOFTWARE\Activision\Battlezone\1.4\","AppPath"); show_message(value); game_end();
The EXE path is now returned to me from the registry.
It was intended to modify BZ and RO render as one, but it wasn't working that way the first time.
It's fixed now.
With N installer, it also installs Red Odyssey in same folder as BattleZone.
So when creating bzpaths.ini, the utility will read BZ path from registry, and assume RO installation to be in same folder.
If BZ is "C:\Program Files\Bz 1.4N\Battlezone\",
RO will be assumed to be: "C:\Program Files\Bz 1.4N\The Red Odyssey\".
It will work just fine even if installation directory is not default. ("C:\Program Files\Bz 1.4N\")
EDIT: Found a minor problem with 2nd upload that was also in 1st: When clicking the Close button, it only saves changes to render.cfg in the utility's directory. It does not copy to BZ and RO like it's supposed to. I fixed that for the 3rd (hopefully final) upload. I'm hoping to eventually get the map loader added, but at the moment, I'm trying to think of a way to code that, while having no luck trying to figure out how to reproduce the "Restore Windows Mouse Cursors" feature of the original utility.
Hey, it's been a while since I created this. If anybody wants my darn good looking utility, it's available. Besides, the original host is down, so perfect time to update the link.
To avoid confusion between the Vista and XP/98 executables, I included only the XP/98 version and a patch you apply for Vista. If you're on Vista, apply the patch, if not, you don't need it. Cheers!
Also, I made the icon look like TRO. I originally stole Leinen's icon, but now it's better, made a new icon for mine.
Fixed a minor bug. "machoman.bzn" didn't exist according to the file_exists() function because it was last modified in 1844 (invalid date), but the file_find*() functions can see it, so I made a work-around:
file_exist
Code:
var f; f = file_find_first(argument0,0); file_find_close(); return (f != "");
This tells me "if a file exists", not "if a file exists with a valid date".
Silly Delphi programmers...
Writing the code to read netmis.txt caused me enough trouble with my own string manipulation mistakes, and then I have my code telling me a file I can SEE in my addon folder does "not exist"... BAH!
Array indexes start at 0, but string positions start at 1... tsk tsk.
Joined: August 20th, 2007, 12:17 pm Posts: 3133 Location: Zagreb, Croatia
"Reload Windows' cursors" is not important feature. Those cursors stopped working as they should since the XP, so I excluded them from the default installer and made them available in the separate folder, for those who really want them.
Enable 3D card is very useful option and mission are easier to pick now. What I don't like is the looks (original ain't pretty either), can you give some alternatives? And what is different in Vista version?
Edit: Easy editor access is great new feature. I can't launch Bz if I have RO opened... can that be changed?
Joined: March 30th, 2008, 3:49 pm Posts: 459 Location: Wherever there is cake
Hm, it's not that important but the music is not working with the RO ISO that is included with the 1998 installation. I havn't tried any other ISO's yet. Also, where did that "demo animation" come from?
"Reload Windows' cursors" is not important feature. Those cursors stopped working as they should since the XP, so I excluded them from the default installer and made them available in the separate folder, for those who really want them.
Enable 3D card is very useful option and mission are easier to pick now. What I don't like is the looks (original ain't pretty either), can you give some alternatives? And what is different in Vista version?
Edit: Easy editor access is great new feature. I can't launch Bz if I have RO opened... can that be changed?
You don't like the look of it? It can be changed. You don't like the background? The text color? I can change almost anything or rework it and make it customizable.
I'll try to explain why I have 2 versions...
According to the documentations for Game Maker 6.1 and 7.0, 6.1's executables works on 98SE and Windows XP. Game Maker 7.0 was made because of Vista incompatibility in 6.1, and it claims 7.0's executables no longer works on versions of Windows 98 The default one works on 98SE and XP, but NOT Vista. The one in the Vista folder works on XP and Vista, but NOT 98SE. Without being able to actually test every OS myself, I just wanted to make sure everybody could run it one way or another. It doesn't run on my VERY OLD Windows 98 eMachines PC. It isn't a perfect replacement for the original utility, because of this and the missing cursor feature. I was really determined to find a way to reload windows cursors in mine, because it could have been done automatically, without even pressing a button.
As for the "Enable 3D Card" box, I already had begun thinking how I could make the level selection feature, but then I literally started thinking "outside the box" (pun intended) and made the level selection different than the original, leaving an empty spot in "Test these Settings" section. So then I thought "What can I put there?". *light bulb appears over head* Ah! HW/SW switch!
Zachtank wrote:
Hm, it's not that important but the music is not working with the RO ISO that is included with the 1998 installation. I havn't tried any other ISO's yet. Also, where did that "demo animation" come from?
ISO in installer doesn't have music, it simply allows you to play. A full RO iso is 565 MB + a few KB for the descriptor. It's a big file, actually 2 files. If you had full ISO and Daemon Tools, you would put "ODYSSEY.MDF" and "ODYSSEY.MDS" somewhere in the same folder together, and in Daemon Tools, you would find and mount the MDS file on the lowest CD drive letter, which might require some slight system modification. My CD ROM drive was Drive D:\, now it's drive J:\ because I re-assigned my virtual drive to be drive D:\. If you have full ISO/CD on any drive except the lowest CD drive letter, the music won't play. It's picky. The CD functionality of Game Maker is the same way, will only work for lowest letter CD drive.
Demo Animation was made by Activision. It will play until you press ESC, then click Abort Mission.
Joined: August 20th, 2007, 12:17 pm Posts: 3133 Location: Zagreb, Croatia
I was thinking on a completely new looks, with different menu too. Simple as render.cfg is, and nicer in the same time, with few more options of course. Things like "Enhanced large textures" and "Test these settings" are confusing. "Large Assets" sounds better.
BTW, your Utility (both versions) doesn't work in Win7, while original (made for Win9x), works in both XP and 7. Haven't tested on Vista, but 7 is as close as it gets.
Text labels for stuff like "Test these Settings", "Enhanced, Large Textures" are easy for me to change, in fact, I added support for a file called "strings.txt" which is roughly equivalent to BZ's "label.map" for what was going to be the next version, but now it seems you want new layout.
As for giving the utility a completely different layout, I might have to start from scratch, but I can re-use old scripts I wrote the first time, so it might not take as long. Draw a sketch in MS Paint or something, then I can get a general idea of what it should look like.
Unfortunately, there is very little I can do to make it compatible with different OS's. One idea though is to revert to an even older version of Game Maker (5.3), who's generated executables run on 98, XP, Vista, and likely Windows 7. It would require me to start over (might take some considerable time), but it might be worth it. Game Maker 5.3 is a version before the developer added Direct3D support, so that probably makes it more compatible. On the other hand, Game Maker 8.0 will be released soon, but I assume it will simply be a step up from 6.x/7.0.
Last edited by Sporkinator on October 16th, 2009, 2:23 am, edited 1 time in total.
You can now start RO even if BZ is already running and vice versa.
This time there are 3 executables. We are going to figure out what OS they all run on.
I named them based on what Game Maker version I created the .exe with. The 5.3 version is the most compatible AFAIK, and the 6.1 and 7.0 versions are more recent, and run more efficiently (assuming they actually run at all on your particular OS). I had to re-work the code after I manually copied all my graphics and code over to old Game Maker 5.3, but the conversion didn't take as long as I thought, only took 2 days.
The layout is unchanged for now, perhaps I'll experiment with new layouts over this next week.
The big question I need answered is: "Does BZConfig9000_v2.3_GM5.3.exe run on Windows 7?"
I already know it runs on Windows 98, Windows XP, and Windows Vista.
EDIT: I included this info and other info in a text file inside the zip archive, but I want to point out that BZConfig9000_v2.3_GM5.3.exe, which is the one that runs on Win98, has a graphical issue related to resolution change. If you launch BZ or RO fullscreen and go back to the utility, the graphics will be missing and I can't fix it. Once you exit the fullscreen game, the utility will be usable again, so hopefully this issue isn't too much of a stumbling block.
No answer to Windows 7 question yet, still haven't implemented any new layout. Battlezone 1998 v1.2 is out (YAY! ) and it has 3 IA missions that 1.1 did not have.
Here's an updated instant_action.txt if you want the 3 IA missions added to the level selection:
Link and is down and no longer needed, as 2.4's instant_action.txt is structured differently, making old one NOT compatible with new version.
It's madness to work on multiple versions of the program, GM 5.3 and GM 6.1/7.0, so I am doing all the development in GM 6.1 as I have before, I'll just manually convert it again to GM 5.3 when I decide to release next version. So far, not much has really changed, other than fixing a few code errors that only I would notice, and adding a new button in place of the where the windows cursor restore button would normally go if I could make it work, just a CD music on/off option.
Meanwhile, this is basically a concept drawing/sketch so far, trying to invent new/better layout: This will most certainly change, the boxes are too close together.
Last edited by Sporkinator on November 19th, 2009, 11:01 pm, edited 1 time in total.
Users browsing this forum: No registered users and 0 guests
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum