mirror of
https://github.com/Phantop/LADXHD.git
synced 2024-11-01 04:14:22 +00:00
32 lines
666 B
C#
32 lines
666 B
C#
|
using System;
|
|||
|
|
|||
|
namespace ProjectZ.InGame.Map
|
|||
|
{
|
|||
|
public class MapStates
|
|||
|
{
|
|||
|
[Flags]
|
|||
|
public enum FieldStates
|
|||
|
{
|
|||
|
None = 0,
|
|||
|
Init = 1,
|
|||
|
Grass = 2,
|
|||
|
Water = 4,
|
|||
|
DeepWater = 8,
|
|||
|
Lava = 16,
|
|||
|
|
|||
|
UpperLevel = 32 | 64,
|
|||
|
Level1 = 32,
|
|||
|
Level2 = 64,
|
|||
|
}
|
|||
|
|
|||
|
public static int GetLevel(FieldStates state)
|
|||
|
{
|
|||
|
if ((state & FieldStates.Level1) != 0)
|
|||
|
return 1;
|
|||
|
if ((state & FieldStates.Level2) != 0)
|
|||
|
return 2;
|
|||
|
|
|||
|
return 0;
|
|||
|
}
|
|||
|
}
|
|||
|
}
|