share/hedgewars/Data/Maps/Basketball/map.lua
author Wuzzy <Wuzzy2@mail.ru>
Mon, 20 May 2019 16:18:35 +0200
changeset 15020 a1165392c9db
parent 14406 6c21bd8547dd
permissions -rw-r--r--
Scenarios: Drawn games count as mission failure
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
4506
37744d5c877e Finnished up the lua translations by adding training maps, campaign is ignored for now
Henek
parents: 4502
diff changeset
     1
-- Hedgewars - Basketball for 2+ Players
3000
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
     2
9093
4114ce5d885d fix locale load
nemo
parents: 8349
diff changeset
     3
HedgewarsScriptLoad("/Scripts/Locale.lua")
3000
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
     4
3240
smxx
parents: 3235
diff changeset
     5
local started = false
smxx
parents: 3235
diff changeset
     6
3000
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
     7
function onGameInit()
3003
0afdba08a858 Engine:
smxx
parents: 3000
diff changeset
     8
	GameFlags = gfSolidLand + gfBorder + gfInvulnerable + gfLowGravity
3000
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
     9
	TurnTime = 20000
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    10
	CaseFreq = 0
4162
923db448ad16 update and fix some lua stuff
Henek
parents: 3465
diff changeset
    11
	MinesNum = 0
3000
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    12
	Explosives = 0
10631
3d164350cc48 make BasketballField available as regular map. maybe should make it destructable when not in mission mode *shrugs*
sheepluva
parents: 9093
diff changeset
    13
    Map = 'BasketballField'
12084
8f222872d432 Disable SD for a couple of scripts and mission maps
Wuzzy <almikes@aol.com>
parents: 12082
diff changeset
    14
	-- Disable Sudden Death
8f222872d432 Disable SD for a couple of scripts and mission maps
Wuzzy <almikes@aol.com>
parents: 12082
diff changeset
    15
	WaterRise = 0
8f222872d432 Disable SD for a couple of scripts and mission maps
Wuzzy <almikes@aol.com>
parents: 12082
diff changeset
    16
	HealthDecrease = 0
3000
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    17
end
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    18
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    19
function onGameStart()
12082
ce3860c82c8b Rewrite 2nd line of mission panel of most missions for consistency
Wuzzy <almikes@aol.com>
parents: 11202
diff changeset
    20
	ShowMission(loc("Basketball"), loc("Not So Friendly Match"), loc("Bat your opponents through the|baskets and out of the map!"), -amBaseballBat, 0)
3240
smxx
parents: 3235
diff changeset
    21
	started = true
3000
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    22
end
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    23
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    24
function onAmmoStoreInit()
3346
967fd96f7373 Engine/Frontend:
smxx
parents: 3266
diff changeset
    25
	SetAmmo(amBaseballBat, 9, 0, 0, 0)
967fd96f7373 Engine/Frontend:
smxx
parents: 3266
diff changeset
    26
	SetAmmo(amSkip, 9, 0, 0, 0)
3000
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    27
end
2b9405b6dc5d General:
smxx
parents: 2999
diff changeset
    28
11202
cc308446f90d preselect baseball bat in Knockball and Basketball
sheepluva
parents: 10631
diff changeset
    29
function onNewTurn()
cc308446f90d preselect baseball bat in Knockball and Basketball
sheepluva
parents: 10631
diff changeset
    30
    SetWeapon(amBaseballBat)
cc308446f90d preselect baseball bat in Knockball and Basketball
sheepluva
parents: 10631
diff changeset
    31
end