mirror of
https://github.com/LDDestroier/CC/
synced 2024-12-14 12:10:29 +00:00
Update tron
This commit is contained in:
parent
50333e7580
commit
f78bb05634
8
tron
8
tron
@ -540,7 +540,7 @@ end
|
||||
|
||||
local titleScreen = function()
|
||||
term.clear()
|
||||
drawImage(images.logo, scr_x / 2 - images.logo.x / 2, 3)
|
||||
drawImage(images.logo, math.ceil(scr_x / 2 - images.logo.x / 2), 3)
|
||||
|
||||
local choice = makeMenu(2, scr_y - 4, {
|
||||
"Start Game",
|
||||
@ -644,19 +644,19 @@ local deadAnimation = function(doSend)
|
||||
if deadGuys[you] and deadGuys[nou] then
|
||||
scrollToPosition(player[nou].x, player[nou].y)
|
||||
scrollToPosition(player[you].x, player[you].y)
|
||||
drawImage(images.tie, math.floor(scr_x / 2 - images.tie.x / 2), math.floor(scr_y / 2 - images.tie.y / 2))
|
||||
drawImage(images.tie, math.ceil(scr_x / 2 - images.tie.x / 2), math.floor(scr_y / 2 - images.tie.y / 2))
|
||||
waitForKey(1)
|
||||
return "end"
|
||||
else
|
||||
if deadGuys[you] then
|
||||
scrollX, scrollY = player[nou].x - scr_x / 2, player[nou].y - scr_y / 2
|
||||
scrollToPosition(player[you].x, player[you].y)
|
||||
drawImage(images.lose, math.floor(scr_x / 2 - images.lose.x / 2), math.floor(scr_y / 2 - images.lose.y / 2))
|
||||
drawImage(images.lose, math.ceil(scr_x / 2 - images.lose.x / 2), math.floor(scr_y / 2 - images.lose.y / 2))
|
||||
waitForKey(1)
|
||||
return "end"
|
||||
elseif deadGuys[nou] then
|
||||
scrollToPosition(player[nou].x, player[nou].y)
|
||||
drawImage(images.win, math.floor(scr_x / 2 - images.win.x / 2), math.floor(scr_y / 2 - images.win.y / 2))
|
||||
drawImage(images.win, math.ceil(scr_x / 2 - images.win.x / 2), math.floor(scr_y / 2 - images.win.y / 2))
|
||||
waitForKey(1)
|
||||
return "end"
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user