Stratagus Configuration Language Description: Triggers
_________ __ __
/ _____// |_____________ _/ |______ ____ __ __ ______
\_____ \\ __\_ __ \__ \\ __\__ \ / ___\| | \/ ___/
/ \| | | | \// __ \| | / __ \_/ /_/ > | /\___ \
/_______ /|__| |__| (____ /__| (____ /\___ /|____//____ >
\/ \/ \//_____/ \/
______________________ ______________________
T H E W A R B E G I N S
Stratagus - A free fantasy real time strategy game engine
(C) Copyright 2004-2006 by The Stratagus Project. Distributed under the
"GNU General Public License"
Stratagus
FAQ
PREV
NEXT
LUA Index
SaveGame
SlotUsage
Intro - Introduction to savegame functions and variables
Everything around save games. All of the functions below are primarily used
in the creation and loading of saved games.
Functions
SaveGame({SyncHash = x, SyncRandSeed = y, SaveFile = "file"})
Basic outline of the savegame, include hashs for syncrand and where to load
the rest of the game information from when loading. More information is planed
for implementation, but currently only the above are used.
- SyncHash = x
- integer setting the Hash of the current game for Sync Purposes
- SyncRandSeed = y
- integer of the next value to be used when calling SyncRand
- SaveFile = "file"
- String containing the name of the file to load to get the rest of the gamedata
Example
SaveGame({
--- "comment", "Generated by Stratagus Version 2.0",
--- "comment", "Visit http://Stratagus.Org for more informations",
--- "comment", "$Id: savegame.html 7629 2006-10-28 18:11:38Z jsalmon3 $",
--- "type", "single-player",
--- "date", "Mon May 10 19:19:38 2004",
--- "map", "",
--- "media-version", "Undefined"--- "engine", {2, 0, 0},
SyncHash = 196009203,
SyncRandSeed = -220040269,
SaveFile = "data.wc2//campaigns/human/level13h.cm"
--- "preview", "/home/devil/.stratagus/wc2/save/current-game.sav.pam",
} )
SlotUsage(MaxSlot, [{Slot = Slot1, FreeCycle = Freecycle1}, ..])
Allows reloaded Save games to be replayed in sync by reloading the released
units back into the queue they were in when a game was saved.
- MaxSlot
- The total Number of slot used.
- Slot
- The Slot Number for the unit that was in the release Queue
- FreecCycle
- The Cycle that this unit is/was released in
Example
SlotUsage(5, {2, 855})
Last changed: $Id: savegame.html 7629 2006-10-28 18:11:38Z jsalmon3 $
All trademarks and copyrights on this page are owned by their respective owners.
(c) 2002-2006 by
The Stratagus Project