SaveGame v. 1.4 (my epeen is bigger!!)

SaveGame v. 1.4 (my epeen is bigger!!)

Discuss Lua based Spring scripts (LuaUI widgets, mission scripts, gaia scripts, mod-rules scripts, scripted keybindings, etc...)

Moderator: Moderators

User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7032
Joined: 16 Nov 2004, 13:08

SaveGame v. 1.4 (my epeen is bigger!!)

Post by zwzsg »

So, Argh told me not to post in his thread. I consider this an unsufferable infrigment of my First Amendment (what do you say? American Constitution doesn't apply to a French posting on an Swedish server?), but then the corrupt moderatoring board has been know to bend to such childish demand. Anyway, so that means I have to create my own thread to tell The World how much more superior my own savegame system is! Yeah, doesn't save heightmap, fugly GUI, crash on loading big savegames, doesn't even attempt to save gadgets data, but it's still awesome because so I say. I had it up and running for a long time in KP, later Gundam, though I just fixed the UnitID translation, and made it save multiple savegames instead of one.

But what is not in Balanced Annihilation does not exists. I mean, what kind of loony would check Kernel Panic or to Gundam RTS? So I ported my save system to BA. Also included is my skirmish generator, though atm difficulty does nothing and it only use KAIK. Oh yeah and:

You must not have any space in your path to Spring.exe
(That limitation will be lifted by Spring 0.81)

Pics:

Image

Image

Image

Note: It is a generic savesystem.
- The only mod-specific stuff in the BA mutator is the menu title.
- The only mod-specific stuff in the Evo mutator is that... oh there is none!
Attachments
Evo25-sav1.sd7
EvoRTS mutator adding savegames.
(41.13 KiB) Downloaded 64 times
BAV7.04-sav1.sd7
BA mutator adding savegames.
(39.51 KiB) Downloaded 100 times
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by smoth »

LOL, I love the post! good job keeping me entertained and interested throughout.
User avatar
CarRepairer
Cursed Zero-K Developer
Posts: 3359
Joined: 07 Nov 2007, 21:48

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by CarRepairer »

zwzsg wrote:So, Argh told me not to post in his thread. I consider this an unsufferable infrigment of my First Amendment (what do you say? American Constitution doesn't apply to a French posting on an Swedish server?),
Server is in Czech Republic now. Better consult an attorney.
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7032
Joined: 16 Nov 2004, 13:08

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by zwzsg »

Does that mean *gasp* that the English lied to me? So we would not be running on a T.V., but on a fridge? My perspectives are all shattered now.



Tried my savegame system on Revelation, saw no issues: REVELATION_R60S1.sd7
R-TEAM
Posts: 177
Joined: 22 Jan 2009, 19:25

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by R-TEAM »

Hi,

will try it ;)
mhhh .. in the past we have no save/load ...
and now 2 systems fight over the user .....
Hope the better wins ;)
R-TEAM
Posts: 177
Joined: 22 Jan 2009, 19:25

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by R-TEAM »

Hi,

its look it works - musst test with a BIG game after 7-10h playing ...
Who i like :
The nice way it is integrated in the spring Ui , arghs system looks mor a
Alien-body on spring and match only good to specifc games ..
The infos over different things - looks more a commercial relase,not more much like "hobby" ....
The skirmish system, not my flavor but nice

Who i dislik:
It needs Tabula map .. but actual is Tabula V3 ....
mmhh ... not more ATM ...

Musst test both systems with an heavy altered map (after many fights/explosions ) and many units .. then i can say who winn the first round .. but it looks ATM from the GUI good to zwzsgs system ..

oh.. forgoten:
and important (for me) is how complicatet its to implement the system in old mods - arghs system is here very easy ....
Actual developed mods will IMHO become the save system at upgrades ..
User avatar
Forboding Angel
Evolution RTS Developer
Posts: 14657
Joined: 17 Nov 2005, 02:43

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by Forboding Angel »

Image

Reading R-Team's posts is like an endurance run.
R-TEAM
Posts: 177
Joined: 22 Jan 2009, 19:25

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by R-TEAM »

Hi,

he,he - sorry for my Suboptimal english ;)

Back on Topic->
Save is "working" ... but loading not ...
Infolog:
Content error: Couldn't load archive 'maps/paradise lost v2.smf' for map 'maps/Paradise Lost v2.smf'.
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7032
Joined: 16 Nov 2004, 13:08

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by zwzsg »

I'll look into that. Thanks for taking the time to test.
Must test both systems with an heavy altered map (after many fights/explosions )
I don't save heightmaps (yet).

but it looks ATM from the GUI good to zwzsgs system ..
I would never have thought anyone would have liked my crude GUI more than Argh's polished bitmaps. But yeah, it could be said I tried to stay faithfull to the grey rectangles of the hard coded GUI. :P

important (for me) is how complicatet its to implement the system in old mods - arghs system is here very easy ....
My system is incredibly easy to implement as well:
- Add the attached files to your mod.
- Done.

What i dislike: It needs Tabula map .. but actual is Tabula V3 .... mmhh ... not more ATM ...
After asking around a bit, I was left under the impression Tabula V2 is still more played than V3.

But feel free to open up \LuaRules\Gadgets\libs\FillModSpecific.lua and edit the list of maps at the end.

Note: for better customisation, you can edit \LuaRules\Gadgets\libs\FillModSpecific.lua

That is not necessary as I put there default values that should work well with any mod. But it gives you a bit more control.

For instance, the menu title default to:
ModSpecific.ModDisplayName=Game.modShortName
which works for any mod, but if you want you can change it to:
ModSpecific.ModDisplayName="Some Name!"

Or, the AI in the skirmish generator is set to KAIK, but if the mod works better with another AI, you can change those ShortName="KAIK" into ShortName="RAI" or whatever.
The skirmish system, not my flavor but nice
Well, I already had it, so I thought I might as well keep it. In fact the skirmish system is the first bit of that single player system I coded. I originally made it for KP which only work on specific maps with specific AI, which is why the choice of maps and AI is a bit constrained. While limiting the AIs to those that have been tested and found working with the mod is a Good Thing, I'm thinking about making a proper map scanner instead of hard coding map names. Though I don't know yet how, or even if possible.
Attachments
Savegame1.41.zip
Put these files in any mod. Bam, savegames!
(36.24 KiB) Downloaded 72 times
User avatar
Forboding Angel
Evolution RTS Developer
Posts: 14657
Joined: 17 Nov 2005, 02:43

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by Forboding Angel »

R-TEAM wrote:Hi,

he,he - sorry for my Suboptimal english ;)

Back on Topic->
Save is "working" ... but loading not ...
Infolog:
Content error: Couldn't load archive 'maps/paradise lost v2.smf' for map 'maps/Paradise Lost v2.smf'.
Hehe, sorry for being rude. This post^^ was very much understandable :-)
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7032
Joined: 16 Nov 2004, 13:08

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by zwzsg »

I just tried that map, save and load worked.

I suggest to delete ArchiveCacheV7.lua and try again. Then look into your /maps/ folder and check if there wouldn't be two maps named ParadiseLost (or variation of). If so, move one away, delete ArchiveCacheV7.lua again, and try again.

If it still crashes, then do that: when Spring is running, alt tab out and save the script.txt that was generated by the lobby and the infolog. Then reload, and after it failed it to reload, save the script.txt that was generated by my code, and the new infolog. Then post both infolog and both script.txt here (or at http://pastebin.com ), along with the savegame file.
R-TEAM
Posts: 177
Joined: 22 Jan 2009, 19:25

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by R-TEAM »

Hi,
zwzsg wrote:I'll look into that. Thanks for taking the time to test.
Must test both systems with an heavy altered map (after many fights/explosions )
I don't save heightmaps (yet).
This make Hope ;) will test then the unit handling only ATM.
zwzsg wrote:
but it looks ATM from the GUI good to zwzsgs system ..
I would never have thought anyone would have liked my crude GUI more than Argh's polished bitmaps. But yeah, it could be said I tried to stay faithfull to the grey rectangles of the hard coded GUI. :P
It is not bad to have a polished bitmap,but it musst fit to the other GUI
elements.And with the very wide range on GUIs oround here, a more basic and neutral way i prefer.
zwzsg wrote:
important (for me) is how complicatet its to implement the system in old mods - arghs system is here very easy ....
My system is incredibly easy to implement as well:
- Add the attached files to your mod.
- Done.
Nice!
zwzsg wrote:
What i dislike: It needs Tabula map .. but actual is Tabula V3 .... mmhh ... not more ATM ...
After asking around a bit, I was left under the impression Tabula V2 is still more played than V3.

But feel free to open up \LuaRules\Gadgets\libs\FillModSpecific.lua and edit the list of maps at the end.
mhhhh .. have thinked the Vx reflect the evolution of the map,like mods.
V1 is the basic version,V2 is improved/bug-fixed and so one .......?
zwzsg wrote:
The skirmish system, not my flavor but nice
Well, I already had it, so I thought I might as well keep it. In fact the skirmish system is the first bit of that single player system I coded. I originally made it for KP which only work on specific maps with specific AI, which is why the choice of maps and AI is a bit constrained. While limiting the AIs to those that have been tested and found working with the mod is a Good Thing, I'm thinking about making a proper map scanner instead of hard coding map names. Though I don't know yet how, or even if possible.
Understand.Good for fast maked fights without long thinking over positions/maps.

By the problem with the map i have no clue ....
Have in my map folder :
....
Palladium_0.5_(beta).sd7
ParadiseLostFix.sd7
Paridise-Dry-V3[1].1.sd7
....
And in ArchiveCache :

Code: Select all

{
			name = "Palladium_0.5_(beta).sd7",
			path = [[E:\Games\Spring\maps\]],
			modified = "1241318596",
			checksum = "3853646429",
			archivedata = {
				name = "Palladium 0.5 (beta).smf",
				mapfile = "maps/Palladium 0.5 (beta).smf",
				modtype = 3,
			},
		},
		{
			name = "ParadiseLostFix.sd7",
			path = [[E:\Games\Spring\maps\]],
			modified = "1232668414",
			checksum = "2697558764",
			archivedata = {
				name = "Paradise Lost v2.smf",
				mapfile = "maps/Paradise Lost v2.smf",
				modtype = 3,
			},
		},
		{
			name = "Paridise-Dry-V3[1].1.sd7",
			path = [[E:\Games\Spring\maps\]],
			modified = "1239282513",
			checksum = "1585593875",
			archivedata = {
				name = "Paridise-Dry-V3.1.smf",
				mapfile = "maps/Paridise-Dry-V3.1.smf",
				modtype = 3,
			},
		},
		{
			name = "Paridise-V2[1].0.sd7",
			path = [[E:\Games\Spring\maps\]],
			modified = "1231624582",
			checksum = "3778524583",
			archivedata = {
				name = "Paridise-V2.0.smf",
				mapfile = "maps/Paridise-V2.0.smf",
				modtype = 3,
			},
		},
		{
			name = "Phobis-One.sd7",
			path = [[E:\Games\Spring\maps\]],
			modified = "1231624594",
			checksum = "831771009",
			archivedata = {
				name = "Phobis-One.smf",
				mapfile = "maps/Phobis-One.smf",
				modtype = 3,
			},
		},
So only one map with this name .....?
The only thing i noticed is the different capitalisation in the infolog ...
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7032
Joined: 16 Nov 2004, 13:08

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by zwzsg »

Hmm, and do you have the same loading problem on other maps, or just this one?


Edit: New version, fixes the problem with large savegames, and manage heightmaps.
Attachments
Savegame1.5.zip
Just merge the file in that zip with your mod.
(39.03 KiB) Downloaded 60 times
R-TEAM
Posts: 177
Joined: 22 Jan 2009, 19:25

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by R-TEAM »

Hi,

Thanks zwzsg ;)
Have testet it ATM with 2 quickly Games,
One with REVELATION_R60 - looks it works nice , but for accurate
statements (over hightmap restoration in details as example) i need test a longer Game.
The second was with Arachnomania .. dont work - the GUI dont apear.
Come errors over Lua Draw .... (have the infolog not more - if you need it i can make additional test to crate infolog)

And it would be nice to can set Filenames and Autosave on/OFF ingame..
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7032
Joined: 16 Nov 2004, 13:08

Re: SaveGame v. 1.51

Post by zwzsg »

-My savegame system (wrongly) assumed a modoptions.lua would always be there.
- Arachnomania used an outdated gadget handler causing a bunch of issue.

Here is a fixed version of Arachnomania: arachnomania_0.8_fr_fixed_2.sd7
(Contains nothing about savegames)

Here is a mutator adding savegame to the Arachnomania just above: arachnomania_0.8_fr_fixed_2_savegame_1.51.sd7
(Nothing arachno specific beside the modinfo.lua)

R-TEAM wrote:And it would be nice to can set Filenames
You can set filename by typing the command manually, in the console that is brought with the enter key. The command is /dump WriteNameHere

R-TEAM wrote:And it would be nice to can set Autosave on/OFF ingame
Yeah, having a couple second freeze every minute because of AutoSave was not nice. In this 1.51 version, AutoSave only save every 5mins, and does not save heightmap (so is practically instant). Indeed a menu to toggle autosave and set its period would be nice, it would be easy to do but it would require a tickbox on the GUI, and I'm not the best GUI designer.




Here is an updated BA mutator adding savegames and one mission:
Attachments
BAV7.1-sav1.52.sd7
To be used with BA71.sd7
(94.17 KiB) Downloaded 63 times
User avatar
Tribulex
A.N.T.S. Developer
Posts: 1894
Joined: 26 Sep 2009, 21:26

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by Tribulex »

YEEEE HAWW!!!!!

i was trying to make my own, and reading this made me realize what i was doing wrong. u just saved my life!!!
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7032
Joined: 16 Nov 2004, 13:08

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by zwzsg »

d_b wrote:i was trying to make my own
Five independendly coded savegame systems, and counting? I sense a phail in the open source sharing model.
User avatar
Tribulex
A.N.T.S. Developer
Posts: 1894
Joined: 26 Sep 2009, 21:26

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by Tribulex »

yeah well, its also my epeen as well. i try to make all my code from scratch, so other people dont whine at me for credit.

EDIT: For example car repairer whined at me for weeks because his stupid "selectionsend" lua was in ANTS.
User avatar
very_bad_soldier
Posts: 1390
Joined: 20 Feb 2007, 01:10

Re: SaveGame v. 1.4 (my epeen is bigger!!)

Post by very_bad_soldier »

d_b wrote:yeah well, its also my epeen as well. i try to make all my code from scratch, so other people dont whine at me for credit.

EDIT: For example car repairer whined at me for weeks because his stupid "selectionsend" lua was in ANTS.
So you implement everything from scratch because you refuse to give credits where it is appropriate? Interesting approach, sir.

Btw you should include "LuaUI/Images/AlliedCursors.png" for the allied cursor widget. Sorry did forget to upload it to widget db myself, but its fixed now.
Post Reply

Return to “Lua Scripts”