fixed spawning and block mechanics
parent
194d3e6130
commit
7109d69f46
|
@ -220,7 +220,7 @@ command /skybattle_setspawner <number> <number>:
|
|||
if arg-2 < 11:
|
||||
if arg-1 is 1:
|
||||
set {skybattle::arena1::spawn_location::%arg-2%} to player's location
|
||||
send "Set spawn location %arg-1%" to player
|
||||
send "Set spawn location %arg-2% in arena %arg-1% to %player's location%" to player
|
||||
else if arg-1 is 2:
|
||||
set {skybattle::arena2::spawn_location::%arg-2%} to player's location
|
||||
send "Set spawn location %arg-1%" to player
|
||||
|
@ -241,43 +241,38 @@ command /skybattle_listspawners <number>:
|
|||
send "Spawn point %loop-number%:" to player
|
||||
send {skybattle::arena%arg-1%::spawn_location::%loop-number%} to player
|
||||
|
||||
command /spawnteam <number> <number>:
|
||||
command /skybattle_spawnteam <number> <number>:
|
||||
trigger:
|
||||
set {skybattle::current_arena} to 0
|
||||
set {skybattle::current_arena} to 1
|
||||
spawnteam(arg-1, arg-2)
|
||||
|
||||
function spawnteam(team: integer, spawner: integer):
|
||||
function spawnteam(team: number, spawner: number):
|
||||
loop entries of team "IDList%{_team}%":
|
||||
broadcast {_team}
|
||||
broadcast {_spawner}
|
||||
broadcast {skybattle::current_arena}
|
||||
if {skybattle::current_arena} is none:
|
||||
teleport loop-value to location at {skybattle::arena%{skybattle::current_arena}%::spawn_location::%{_spawner}%}
|
||||
teleport loop-value to location at {skybattle::arena%{skybattle::current_arena}%::spawn_location::%{_spawner}%}
|
||||
set loop-value's gamemode to survival
|
||||
|
||||
# !!! POPULATE INVENTORY !!!
|
||||
give loop-value iron pickaxe of efficiency 3
|
||||
if {_team} is 1:
|
||||
give loop-value 64 red concrete named "§7Blocks"
|
||||
give loop-value 64 red concrete# named "§7Blocks"
|
||||
if {_team} is 2:
|
||||
give loop-value 64 yellow concrete named "§7Blocks"
|
||||
give loop-value 64 yellow concrete# named "§7Blocks"
|
||||
if {_team} is 3:
|
||||
give loop-value 64 orange concrete named "§7Blocks"
|
||||
give loop-value 64 orange concrete# named "§7Blocks"
|
||||
if {_team} is 4:
|
||||
give loop-value 64 lime concrete named "§7Blocks"
|
||||
give loop-value 64 lime concrete# named "§7Blocks"
|
||||
if {_team} is 5:
|
||||
give loop-value 64 green concrete named "§7Blocks"
|
||||
give loop-value 64 green concrete# named "§7Blocks"
|
||||
if {_team} is 6:
|
||||
give loop-value 64 light blue concrete named "§7Blocks"
|
||||
give loop-value 64 light blue concrete# named "§7Blocks"
|
||||
if {_team} is 7:
|
||||
give loop-value 64 cyan concrete named "§7Blocks"
|
||||
give loop-value 64 cyan concrete# named# "§7Blocks"
|
||||
if {_team} is 8:
|
||||
give loop-value 64 blue concrete named "§7Blocks"
|
||||
give loop-value 64 blue concrete# named# "§7Blocks"
|
||||
if {_team} is 9:
|
||||
give loop-value 64 pink concrete named "§7Blocks"
|
||||
give loop-value 64 pink concrete# named# "§7Blocks"
|
||||
if {_team} is 10:
|
||||
give loop-value 64 purple concrete named "§7Blocks"
|
||||
give loop-value 64 purple concrete# named# "§7Blocks"
|
||||
|
||||
function resetteams():
|
||||
loop 10 times:
|
||||
|
@ -315,11 +310,8 @@ function init_team_names():
|
|||
loop 10 times:
|
||||
set {skybattle::team%loop-number%::name} to {_team%loop-number%}
|
||||
|
||||
|
||||
on place:
|
||||
#if {skybattle::game_status} is "playing":
|
||||
if name of held item is "§7Blocks":
|
||||
give held item to the player
|
||||
on block place of concrete:
|
||||
remove 1 of event-block from player's inventory
|
||||
|
||||
on death of player: # victim, attacker
|
||||
add victim's uuid to {skybattle::deadplayers::*}
|
||||
|
|
Loading…
Reference in New Issue