project-navigation
Personal tools

Author Topic: Edit Saved Games  (Read 52199 times)

Offline Valaska

  • Rookie
  • ***
  • Posts: 17
    • View Profile
Edit Saved Games
« on: May 19, 2008, 09:32:39 pm »
 Heya guys! Hows things going? Well.. I'm not going to get anywhere if I wait for you to answer! So!

 I was wondering if there is any way to edit saved games, right now I am on a Medium campaign and I got 16 soldiers.. I was wondering if I could edit it so there are more soldiers I can hire, and have more funds.. I have  6600000 Credit right now, but more soldiers make many expensives!

 Thanks for reading.

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Edit Saved Games
« Reply #1 on: May 19, 2008, 10:21:12 pm »
you can set the cvar save_compressed to 0 and edit the savegame with a hexeditor

Offline Valaska

  • Rookie
  • ***
  • Posts: 17
    • View Profile
Re: Edit Saved Games
« Reply #2 on: May 19, 2008, 11:04:18 pm »
Ok.. Now where do I find all this and whats a hex editor and will this break any of the stuff I have now?? I don't spend much time here on the computer so I need more directions than that lol.

Offline BTAxis

  • Administrator
  • PHALANX Commander
  • *******
  • Posts: 2607
    • View Profile
Re: Edit Saved Games
« Reply #3 on: May 19, 2008, 11:25:03 pm »
Uh, what did you think editing savegames would be like?

Offline BAM

  • Rookie
  • ***
  • Posts: 79
    • View Profile
Re: Edit Saved Games
« Reply #4 on: May 19, 2008, 11:33:31 pm »
Is is possible to edit the teams you have saved in the Windows version? I know they are in %APPDATA% but they look like gibberish except for the soldier names and some equipment names.

Offline BTAxis

  • Administrator
  • PHALANX Commander
  • *******
  • Posts: 2607
    • View Profile
Re: Edit Saved Games
« Reply #5 on: May 20, 2008, 12:19:53 am »
That's because the values aren't stored as text. They're stored as "real" numbers. Since letters on your screen are actually also numeric values, and you try to display the save file in a viewer, it will look like gibberish because it's trying to display the numbers as characters. To view or edit the actual values you need a HEX editor, and you need to know how hexadecimal numbering works.

Offline BAM

  • Rookie
  • ***
  • Posts: 79
    • View Profile
Re: Edit Saved Games
« Reply #6 on: May 20, 2008, 03:38:05 am »
Then I must need to learn hex; I tried a hex editor and could only find names, weapons, and the team name. (I want to edit their skills)

Offline Valaska

  • Rookie
  • ***
  • Posts: 17
    • View Profile
Re: Edit Saved Games
« Reply #7 on: May 20, 2008, 03:59:40 am »
 I expected it to be just like changing the parameters of a campaign, sorry I don't sit on my computer 34/7 but I just don't have the time hence why I wanted to know if he could tell me more in depth.

Offline BAM

  • Rookie
  • ***
  • Posts: 79
    • View Profile
Re: Edit Saved Games
« Reply #8 on: May 20, 2008, 04:25:34 am »
I've found a nice hex->dec / dec->hex converter - http://www.statman.info/conversions/hexadecimal.html. As for a hex editor, I used the one at http://www.physics.ohio-state.edu/~prewett/hexedit/. I could modify everything but the accuracy etc. - could edit the skills, equipment, etc. The files are in %APPDATA%\UFOAI\2.x\base\save\teamx.mbt.

EDIT: Sorry, figured out a minute later how to edit (traits?) and HP. Just need to convert + search...
« Last Edit: May 20, 2008, 04:33:39 am by BAM »

Offline Valaska

  • Rookie
  • ***
  • Posts: 17
    • View Profile
Re: Edit Saved Games
« Reply #9 on: May 20, 2008, 06:04:25 am »
Thanks BAM! I figured it out, any-who! Sleep now, work tomorrow, then some edited UFO! lol.

Offline Destructavator

  • Combination Multiple Specialty Developer
  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 1908
  • Creater of Scorchcrafter, knows the zarakites...
    • View Profile
Re: Edit Saved Games
« Reply #10 on: May 20, 2008, 02:39:11 pm »
LOL, this thread just cracked me up - sorry, but I just had to get that out.

If you're looking to alter things in the game, I'd start by editing the .ufo files, which on Windows can be altered with a standard text editor (such as notepad, no hex editor required).  I think that would be a much easier approach with a lot less work - those .ufo files allow changes to just about everything (how much money you start with, weapon stats and firemodes, base facility capacity, etc., etc.).

I think I see where you're coming from though, if you're rather new to the project - I remember days when I would look for editors for a lot of commercial games, and try to alter things myself, sometimes with hex editors.  This project is a bit different, it's open-source, anyone can alter the source code if they know how to program in C, and if they aren't a programmer they can still do quite a bit with the .ufo files to re-work the game.  The whole project is fairly open, there's really no need to try to "hack" it.

If you're running windows and want to change things in-game, or outright "cheat," you might also look into a program called GameWiz32 (Google it and you'll get download links from various places).  It's creator no longer has his website up, but it's still on a lot of download servers out there, and it is very quick and easy to use (no programming knowledge required, it alters memory while the game is running to give you more money, freeze health or ammunition while playing, etc.)  Please note before you grab it though, that I don't know if it's completely clean or not.  Download.com and other such sites say it is clean, but I've known for them to occasionally miss some adware-type stuff.  I will say that I tried it a long time ago and never had any issues from it, and it works with almost any game.

Offline BTAxis

  • Administrator
  • PHALANX Commander
  • *******
  • Posts: 2607
    • View Profile
Re: Edit Saved Games
« Reply #11 on: May 20, 2008, 05:26:25 pm »
Oh, don't say that. I found it useful to hack multiplayer teams when experimenting around with the accuracy code. It's a lot less work to manually set up a soldier to have exactly those stats you want than to temporarily modify the code to make soldiers show up with those stats and having to make a new team for every stat configuration.

Offline BAM

  • Rookie
  • ***
  • Posts: 79
    • View Profile
Re: Edit Saved Games
« Reply #12 on: May 20, 2008, 09:50:08 pm »
True that you only need a text editor for the .ufo files, but if you want to modify your teams stats...

Offline [Luke]

  • Cannon Fodder
  • **
  • Posts: 4
    • View Profile
Edit Saved Game parts, like position of an aircraft?
« Reply #13 on: November 20, 2009, 09:41:35 pm »
I know it's old topic, but better here than a new one

I'm wondering about all that savegame stuff: Lot of people seem to intend changing the team stats.
As far as I understood, u've to cvar save_compressed 0 and than change the .ufo- and .pk-file, right?
Not the slotxx.lint and slotxx.xml -files, right?

How bout changing things like position and armory of an aircraft.

F.e I had a team out, on way back home, but the vehicle is shot down by another Ufo right after leaving crashbattlescene with no chance of beeing rescued.

Unfortunately I overwrote older savegames, where the ship wasn't started yet.
So I wonder if I can change the positon f.e.

As far as I recognize, the .lint-Files actually seem to include position, armory and so on, as <>-Values.
But changing them changes nothing.
Wrong file?

Thanks. ;)

Offline geever

  • Project Coder
  • PHALANX Commander
  • ***
  • Posts: 2561
    • View Profile
Re: Edit Saved Games
« Reply #14 on: November 20, 2009, 11:46:49 pm »
What should I say... CHEATER!! :P

-geever