hopefully fixed border bug
parent
f35b780181
commit
0c112e2c04
|
@ -90,6 +90,7 @@ command /minigame_skybattle_start:
|
|||
|
||||
resetplayers()
|
||||
resetteams()
|
||||
resetborder()
|
||||
|
||||
set {skybattle::current_arena} to 0
|
||||
clear inventory of {skybattle::gaming_players::*}
|
||||
|
@ -109,6 +110,7 @@ command /minigame_skybattle_start:
|
|||
clear inventory of {skybattle::gaming_players::*}
|
||||
|
||||
if {skybattle::current_arena} is 1:
|
||||
resetborder()
|
||||
set {skybattle::stop_players} to "True"
|
||||
execute console command "/scoreboard players set Kola XD 1"
|
||||
setbordercenter()
|
||||
|
@ -126,6 +128,7 @@ command /minigame_skybattle_start:
|
|||
spawnteam(10, 10)
|
||||
|
||||
if {skybattle::current_arena} is 2:
|
||||
resetborder()
|
||||
set {skybattle::stop_players} to "True"
|
||||
execute console command "/scoreboard players set Kola XD 2"
|
||||
setbordercenter()
|
||||
|
@ -143,6 +146,7 @@ command /minigame_skybattle_start:
|
|||
spawnteam(10, 9)
|
||||
|
||||
if {skybattle::current_arena} is 3:
|
||||
resetborder()
|
||||
set {skybattle::stop_players} to "True"
|
||||
execute console command "/scoreboard players set Kola XD 3"
|
||||
setbordercenter()
|
||||
|
@ -304,7 +308,7 @@ function setbordercenter():
|
|||
set {_w} to world("021")
|
||||
set {_b} to {_w}.getWorldBorder()
|
||||
{_b}.setDamageBuffer(0)
|
||||
{_b}.setDamageAmount(2)
|
||||
{_b}.setDamageAmount(0.3)
|
||||
{_b}.setCenter({_x}, {_z})
|
||||
|
||||
function changeborder(size: number, time: number):
|
||||
|
@ -312,6 +316,10 @@ function changeborder(size: number, time: number):
|
|||
set {_b} to {_w}.getWorldBorder()
|
||||
{_b}.setSize({_size}, {_time})
|
||||
|
||||
function resetborder():
|
||||
set {_w} to world("021")
|
||||
set {_b} to {_w}.getWorldBorder()
|
||||
{_b}.reset()
|
||||
|
||||
command /skybattle_setborder <number>:
|
||||
description: Set center of border for map x
|
||||
|
|
Loading…
Reference in New Issue