[editor] tanks colors
This commit is contained in:
@@ -1,13 +1,15 @@
|
||||
package ru.m.tankz.core;
|
||||
|
||||
import ru.m.tankz.config.Config.EagleConfig;
|
||||
import haxework.color.Color;
|
||||
import ru.m.geom.Rectangle;
|
||||
import ru.m.tankz.config.Config;
|
||||
import ru.m.tankz.Type;
|
||||
|
||||
class Eagle extends Entity {
|
||||
|
||||
public var team(default, null):TeamId;
|
||||
public var config(default, null):EagleConfig;
|
||||
public var color(default, default):Color;
|
||||
public var death(default, default):Bool;
|
||||
public var protect(default, null):Modificator;
|
||||
|
||||
|
||||
@@ -139,6 +139,7 @@ class Game {
|
||||
var eaglePoint = team.spawner.getPoint('eagle');
|
||||
if (eaglePoint != null) {
|
||||
var eagle = new Eagle(team.id, team.config.eagle);
|
||||
eagle.color = config.getColor(new PlayerId(eagle.team, -1));
|
||||
team.eagleId = eagle.id;
|
||||
applyPoint(eagle, eaglePoint);
|
||||
engine.spawn(eagle);
|
||||
|
||||
Reference in New Issue
Block a user