[common] split player and control

This commit is contained in:
2018-01-22 12:41:40 +03:00
parent 223ff5ba93
commit ce343148c7
6 changed files with 85 additions and 33 deletions

View File

@@ -1,5 +1,6 @@
package ru.m.tankz.view.frames;
import ru.m.tankz.control.PlayerControl;
import flash.events.Event;
import haxe.Timer;
import haxework.gui.VGroupView;
@@ -32,6 +33,8 @@ class GameFrame extends VGroupView implements ViewBuilder implements IPacketHand
humans: 1,
bots: 3,
});
game.setControl('player', 0, PlayerControl.forPlayer(0));
//game.setControl('player', 1, PlayerControl.forPlayer(1));
content.addEventListener(Event.ENTER_FRAME, redraw);
Provider.get(IConnection).packetHandler.addListener(this);
render.draw(game.engine);