Renderování textu, jumpscary, win a lose screen

This commit is contained in:
Perry 2026-03-09 20:05:21 +01:00
parent 9bfe63a166
commit e6128dc9f5
21 changed files with 360 additions and 84 deletions

View file

@ -34,8 +34,8 @@ public class GameLogic {
Server.SendPacket(new MapInitPacket{Connectors = connectorsConverted, UpsideDown = false}, Server.P1.peer);
Server.SendPacket(new MapInitPacket{Connectors = connectorsConverted, UpsideDown = true}, Server.P2.peer);
// EnemyManager.AddEnemy(new LurkEnemy(0)).Spawn(MapManager.Get(12));
EnemyManager.AddEnemy(new NekoEnemy(10)).Spawn(MapManager.Get(2));
EnemyManager.AddEnemy(new LurkEnemy(10)).Spawn(MapManager.Get(12));
EnemyManager.AddEnemy(new NekoEnemy(0)).Spawn(MapManager.Get(2));
EnemyManager.AddEnemy(new SpotEnemy(0)).Spawn(MapManager.Get(12));
secondCycleTimer.Start();
@ -47,5 +47,10 @@ public class GameLogic {
NSecondUpdate = false;
}
public static void DeclareWinner(ServerPlayer player) {
Server.SendUpdateToAll([GameEvent.PLAYER_WIN(player.state.pid)]);
Server.Stop();
Console.WriteLine("Player " + player.state.pid + " won!");
}
}