game config refactoring

This commit is contained in:
2018-01-06 15:38:27 +03:00
parent 58ed988f75
commit 6ae91246ef
6 changed files with 51 additions and 42 deletions

View File

@@ -9,7 +9,7 @@ import protohx.Message;
import ru.m.tankz.proto.pack.GameUpdateResponse;
import ru.m.core.connect.IConnection;
import haxework.gui.ViewBuilder;
import ru.m.tankz.config.TankzConfig;
import ru.m.tankz.config.Config;
import flash.events.Event;
import haxework.provider.Provider;
import haxework.gui.VGroupView;
@@ -31,7 +31,7 @@ class GameFrame extends VGroupView implements ViewBuilder implements IPacketHand
public function onShow():Void {
var game:Game = Provider.get(Game);
engine.init(ConfigData.get(GameType.CLASSIC));
engine.init(ConfigBundle.get(GameType.CLASSIC));
engine.initTanks(game.players);
content.addEventListener(Event.ENTER_FRAME, updateGame);
for (index in 0...game.players.length) {