problems : - there were no test scene - units would appear weird over some tiles - units would not recognize some tiles when trying to know if it could place itself on it solution : - added test scene - tweaked sorting layers in units - added IsCollidable parameter in ILevelObject
23 lines
516 B
C#
23 lines
516 B
C#
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
public interface ILevelObject
|
|
{
|
|
public enum ObjectType
|
|
{
|
|
Tile = 0,
|
|
Prefab = 1,
|
|
Tilemap = 2
|
|
}
|
|
|
|
bool IsCollidable { get; }
|
|
string Name { get; }
|
|
Vector3 Position { get; }
|
|
void LevelUpdate();
|
|
void LevelStart();
|
|
void LevelDestroy();
|
|
bool Equals(ILevelObject other);
|
|
Dictionary<string, object> ToDictionary();
|
|
void LoadDictionary(Dictionary<string, object> dict);
|
|
void RemoveFromLevel();
|
|
} |