mirror of
https://github.com/LDDestroier/CC/
synced 2025-01-22 15:06:52 +00:00
Update tron
This commit is contained in:
parent
cf5a4a5b36
commit
19b7c36be6
7
tron
7
tron
@ -651,11 +651,15 @@ local moveTick = function(doSend)
|
|||||||
for i = 1, #player do
|
for i = 1, #player do
|
||||||
p = player[i]
|
p = player[i]
|
||||||
if not p.dead then
|
if not p.dead then
|
||||||
|
if getTrail(p.x, p.y) or doesIntersectBorder(p.x, p.y) then
|
||||||
|
p.dead = true
|
||||||
|
deadGuys[i] = true
|
||||||
|
else
|
||||||
if isHost then
|
if isHost then
|
||||||
p.x = p.x + math.floor(math.cos(math.rad(p.direction * 90)))
|
p.x = p.x + math.floor(math.cos(math.rad(p.direction * 90)))
|
||||||
p.y = p.y + math.floor(math.sin(math.rad(p.direction * 90)))
|
p.y = p.y + math.floor(math.sin(math.rad(p.direction * 90)))
|
||||||
end
|
end
|
||||||
if getTrail(p.x, p.y) or (p.x == grid.x1 or p.x == grid.x2 or p.y == grid.y1 or p.y == grid.y2) then
|
if getTrail(p.x, p.y) or doesIntersectBorder(p.x, p.y) then
|
||||||
p.dead = true
|
p.dead = true
|
||||||
deadGuys[i] = true
|
deadGuys[i] = true
|
||||||
elseif isHost then
|
elseif isHost then
|
||||||
@ -665,6 +669,7 @@ local moveTick = function(doSend)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
ageTrails()
|
ageTrails()
|
||||||
return deadAnimation(doSend)
|
return deadAnimation(doSend)
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user