updates
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6372 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
+2
-1
@@ -34,4 +34,5 @@ survNumBots = 12
|
||||
survBotsToAdd = 1
|
||||
timeBetChkPts = 60000
|
||||
timeUntilTele = 120000
|
||||
survMaxBots = 32
|
||||
survMaxBots = 32
|
||||
tmpSurvData =
|
||||
+14
-8
@@ -4,7 +4,8 @@
|
||||
// * Each map has a unique "zone" that the player must stay in, to continue playing.
|
||||
// * Every "zone" is located somewhere other than the usual two bases.
|
||||
// * When the player first enters the "zone", the timers/counters start.
|
||||
// * If the player has not found the zone within the set timeframe, they are automatically teleported there.
|
||||
// * If the player has not found the "zone" within the set timeframe, they are automatically teleported there.
|
||||
// * The difficulty is "increased" over time, by spawning more and increasing the skill level of bots at "checkpoints".
|
||||
// * If the player dies, or leaves the "zone" for too long of a duration, the game ends.
|
||||
// * Total seconds survived, and total number of enemies killed during, are reported as stats when the game ends.
|
||||
|
||||
@@ -15,7 +16,7 @@ survResetAliases = "gotCheckPoint lastCheckPoint survIsFinished startedSurvival
|
||||
resetSurvAliases = [
|
||||
loop rsa (listlen $survResetAliases) [ (at $survResetAliases $rsa) = 0 ]
|
||||
checkSurvAliases survMap (rnd (listlen $defaultmaps))
|
||||
checkSurvAliases survBotsToAdd 1; checkSurvAliases survDifficulty 0; checkSurvAliases survNumBots 12; checkSurvAliases survMaxBots 32; checkSurvAliases timeBetChkPts 60000
|
||||
checkSurvAliases survBotsToAdd 1; checkSurvAliases survDifficulty 0; checkSurvAliases survNumBots 12; checkSurvAliases survMaxBots 32; checkSurvAliases timeBetChkPts 60000; checkSurvAliases timeUntilTele 120000
|
||||
]
|
||||
|
||||
resetSurvAliases
|
||||
@@ -33,8 +34,7 @@ survival = [
|
||||
]
|
||||
|
||||
startSurvival = [
|
||||
startedSurvival = 1; startSurvMillis = (millis)
|
||||
addnbot $survNumBots CLA bad
|
||||
startedSurvival = 1; startSurvMillis = (millis); addnbot $survNumBots CLA bad
|
||||
sleep 2500 [ if $survTeleported [ echo (c 9)You were teleported to the zone. ]; echo (c 3)Starting survival mode, good luck! ]
|
||||
sleep $timeBetChkPts [ gotCheckPoint = 1; increaseDifficulty ]
|
||||
]
|
||||
@@ -91,7 +91,7 @@ findCenter = [
|
||||
tmpZoneCenter = (concat $midZoneX $midZoneY)
|
||||
]
|
||||
|
||||
teleportPlayer = [ if (! (alive)) [ attack ]; if (!= $gamespeed 100) [ gamespeed 100 ]; survTeleported = 1; findCenter; if (! $editing) [ edittoggle ]; go_to (at $tmpZoneCenter 0) (at $tmpZoneCenter 1); sleep 50 [ edittoggle ] ]
|
||||
teleportPlayer = [ if (! (alive)) [ attack ]; if (!= $gamespeed 100) [ gamespeed 100 ]; survTeleported = 1; findCenter; if (! $editing) [ edittoggle ]; go_to (at $tmpZoneCenter 0) (at $tmpZoneCenter 1); sleep 25 [ edittoggle ] ]
|
||||
|
||||
isInZone = [
|
||||
if (&& (&& (>= (getposition 0) (at $zone 0)) (>= (getposition 1) (at $zone 2))) (&& (<= (getposition 0) (at $zone 1)) (<= (getposition 1) (at $zone 3)))) [
|
||||
@@ -132,7 +132,13 @@ endSurvival = [
|
||||
tdm (at $defaultmaps (rnd (listlen $defaultmaps)))
|
||||
]
|
||||
|
||||
// List of aliases that need to be cleared from saved.cfg on quit:
|
||||
survAliases = "backInZone checkzone curSurvDifficulty endSurvival finalSurvMillis gotCheckPoint increaseDifficulty isInZone lastCheckPoint midZoneX midZoneY onKill resetSurvAliases setOfcZones setzone startedOBCount startedSurvival startOBCount startOBMillis startPreSurvMillis startSurvival startSurvMillis survIsFinished survival_test survKills survMapIndex survOfcZones survTeleported tmpSurvCtr tmpSurvInt tmpSurvSets tmp_survstr tmpSurvZone tmpZoneCenter zone checkSurvAliases survResetAliases survAliases"
|
||||
// Use a single alias to store data rather than many
|
||||
survSaveAliases = "survMaxBots survDifficulty timeBetChkPts survNumBots survBotsToAdd timeUntilTele survMap"
|
||||
if (! (checkalias afterinit)) [ afterinit = "" ]
|
||||
if (! (strstr $afterinit tmpSurvData)) [ add2alias afterinit [ if (checkalias tmpSurvData) [ if (= (listlen $tmpSurvData) (listlen $survSaveAliases)) [ loop oll (listlen $survSaveAliases) [ (at $survSaveAliases $oll) = (at $tmpSurvData $oll) ] ] ] ] ]
|
||||
addOnQuit [ tmpSurvData = ""; loop oql (listlen $survSaveAliases) [ add2list tmpSurvData (getalias (at $survSaveAliases $oql)) ] ]
|
||||
|
||||
addListOnQuit $survAliases
|
||||
// List of aliases that need to be cleared from saved.cfg on quit:
|
||||
survAliases = "backInZone checkzone curSurvDifficulty endSurvival finalSurvMillis gotCheckPoint increaseDifficulty isInZone lastCheckPoint midZoneX midZoneY onKill resetSurvAliases setOfcZones setzone startedOBCount startedSurvival startOBCount startOBMillis startPreSurvMillis startSurvival startSurvMillis survIsFinished survival_test survKills survMapIndex survOfcZones survTeleported tmpSCtr tmpSurvCtr tmpSurvInt tmpSurvSets tmp_survstr tmpSurvZone tmpZoneCenter zone checkSurvAliases survResetAliases survAliases"
|
||||
|
||||
addListOnQuit $survAliases; addListOnQuit $survSaveAliases
|
||||
Reference in New Issue
Block a user