summaryrefslogtreecommitdiffstats
path: root/Plugins/Core.lua
diff options
context:
space:
mode:
authorfaketruth <faketruth@0a769ca7-a7f5-676a-18bf-c427514a06d6>2011-11-01 22:57:08 +0100
committerfaketruth <faketruth@0a769ca7-a7f5-676a-18bf-c427514a06d6>2011-11-01 22:57:08 +0100
commitb5b920dedaa62302795b0b8f3db84a0650d236e0 (patch)
treef46d1ec70d6519fff2a75f45c08fe37bf4b5538c /Plugins/Core.lua
parentforogt to update all of cPlayer.cpp for player based gamemode. (diff)
downloadcuberite-b5b920dedaa62302795b0b8f3db84a0650d236e0.tar
cuberite-b5b920dedaa62302795b0b8f3db84a0650d236e0.tar.gz
cuberite-b5b920dedaa62302795b0b8f3db84a0650d236e0.tar.bz2
cuberite-b5b920dedaa62302795b0b8f3db84a0650d236e0.tar.lz
cuberite-b5b920dedaa62302795b0b8f3db84a0650d236e0.tar.xz
cuberite-b5b920dedaa62302795b0b8f3db84a0650d236e0.tar.zst
cuberite-b5b920dedaa62302795b0b8f3db84a0650d236e0.zip
Diffstat (limited to '')
-rw-r--r--Plugins/Core.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/Plugins/Core.lua b/Plugins/Core.lua
index e124a9261..4438401a9 100644
--- a/Plugins/Core.lua
+++ b/Plugins/Core.lua
@@ -115,7 +115,7 @@ function CorePlugin:Initialize()
end
function HandleTopCommand( Split, Player )
- local World = cRoot:Get():GetWorld()
+ local World = Player:GetWorld()
local PlayerPos = Player:GetPosition()
local Height = World:GetHeight( math.floor(PlayerPos.x), math.floor(PlayerPos.z) )
@@ -218,7 +218,7 @@ function ShowMOTDTo( Player )
end
function HandleSpawnCommand( Split, Player )
- World = cRoot:Get():GetWorld()
+ World = Player:GetWorld()
Player:TeleportTo( World:GetSpawnX(), World:GetSpawnY(), World:GetSpawnZ() )
LOGINFO( Player:GetName() .. " returned to spawn." )
return true