public void makeUnit(Actor p, HexLoc loc) { Unit u = new GameObject("Unit").AddComponent <Unit> (); u.init(p, this, map [loc]); units.Add(u); UnityEngine.Debug.Log("Added Unit at " + loc.ToString()); }
public void makeHex(HexLoc l) { var obj = new GameObject(l.ToString()); obj.transform.parent = hFolder.transform; Hex h = obj.AddComponent <Hex>(); h.init(this, l); map.Add(l, h); }
public Hex addHex(HexLoc hl) { Hex h = new GameObject("Hex " + hl.ToString()).AddComponent <Hex> (); h.init(this, hl); h.transform.parent = hexes.transform; map.Add(hl, h); return(h); }
public void makeMiasma(HexLoc loc, int aggression) { if (map [loc].miasma != null) { return; } Miasma m = new GameObject("Miasma").AddComponent <Miasma> (); m.init(this, map [loc], aggression); UnityEngine.Debug.Log("Added Miasma at " + loc.ToString()); }