// Use this for initialization void Start() { DontDestroyOnLoad(gameObject); hotbar_prefab = hotbar_ref; sprite_prefab = sprite_ref; pickup_prefab = pickup_ref; g_manager = GameObject.Find("Game Manager").GetComponent <game_manager>(); i_manager = GameObject.Find("Item Manager").GetComponent <item_manager>(); e_manager = GameObject.Find("Enemy Manager").GetComponent <enemy_manager>(); b_manager = GameObject.Find("Enemy Manager").GetComponent <boss_manager>(); p_manager = GameObject.Find("Player Manager").GetComponent <player_manager>(); perks = GameObject.Find("Player Manager").GetComponent <perk_manager>(); feature_spawner = GameObject.Find("Map Manager").GetComponent <map_feature_spawner>(); m_gen = GameObject.Find("Map Manager").GetComponent <map_generator>(); v_manager = GameObject.Find("Map Manager").GetComponent <fov_manager>(); d_manager = GameObject.Find("Dijkstra Manager").GetComponent <dijkstra_manager>(); events = GameObject.Find("Event Manager").GetComponent <event_manager>(); game_master = new rpg_character(); colors = new Color[7]; colors[0] = Color.green; colors[1] = Color.red; colors[2] = Color.blue; colors[3] = Color.cyan; colors[4] = Color.magenta; colors[5] = Color.yellow; colors[6] = Color.grey; up = new Vector2Int(0, 1); down = new Vector2Int(0, -1); left = new Vector2Int(-1, 0); right = new Vector2Int(1, 0); }
// Use this for initialization void Start() { DontDestroyOnLoad(gameObject); features = GameObject.Find("Map Manager").GetComponent <map_feature_spawner>(); d_manager = GameObject.Find("Dijkstra Manager").GetComponent <dijkstra_manager>(); f_manager = GameObject.Find("Map Manager").GetComponent <fov_manager>(); s_weight = 1f; a_weight = 1f; m_weight = 1f; }
public void initialize() { floor_map = GameObject.Find("Floor").GetComponent <Tilemap>(); wall_map = GameObject.Find("Blocking Layer").GetComponent <Tilemap>(); floor_map.size = new Vector3Int(x_dim, y_dim, 0); wall_map.size = new Vector3Int(x_dim, y_dim, 0); features = gameObject.GetComponent <map_feature_spawner>(); palette_tiles = GameObject.Find("Palette").transform.GetChild(0).GetComponent <Tilemap>(); wall_tiles = new TileBase[21]; floor_tiles = new TileBase[6]; set_palette(); is_floor = new bool[x_dim, y_dim]; }
// Use this for initialization void Start() { DontDestroyOnLoad(gameObject); features = GameObject.Find("Map Manager").GetComponent <map_feature_spawner>(); }