-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTypes.cs
93 lines (89 loc) · 3.2 KB
/
Types.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Drawing;
namespace ROQWE
{
class Types
{
readonly static Color door = Color.Brown;
readonly static Color snake = Color.Green;
readonly static Color wall = Color.Black;
readonly static int player = Loader.LoadTexture("images.jpg");
readonly static Color floor = Color.Gray;
public const char snakeType = 'S';
public const char wallType = '#';
public const char playerType = '@';
public const char doorType = 'D';
public const char floorType = '_';
/// <summary>
/// makes a entity type based on default values (in the future from an xml file)
/// </summary>
/// <param name="x"></param>
/// <param name="y"></param>
/// <param name="z"></param>
/// <returns></returns>
public static Entity Snake(int x, int y, int z)
{
return new Entity(x, y,z, snakeType, Guid.NewGuid(), new Cube(x,y,z,Game.Scale, Game.Scale, Game.Scale, snake), new Stats(10,1,10));
}
public static Entity Wall(int x, int y, int z)
{
return new Entity(x, y,z, wallType, Guid.NewGuid(), new Cube(x, y,z, Game.Scale, Game.Scale, Game.Scale, wall), new Stats(1, 1, 1));
}
public static Entity Player(int x, int y, int z)
{
return new Entity(x, y,z, playerType, Guid.NewGuid(), new Cube(x,y,z, Game.Scale, Game.Scale, Game.Scale, player), new Stats(100, 10, 10));
}
public static Entity Door(int x, int y, int z)
{
return new Entity(x, y,z, doorType, Guid.NewGuid(), new Cube(x,y,z, Game.Scale, Game.Scale, Game.Scale, door), new Stats(1, 1, 1));
}
public static Entity Floor(int x, int y, int z)
{
return new Entity(x, y,z, floorType, Guid.NewGuid(), new Cube(x,y,z, Game.Scale, Game.Scale, 0.01f, floor), new Stats(1, 1, 1));
}
public static Entity Door(IntVector3D Pos)
{
return Door(Pos.X, Pos.Y, Pos.Z);
}
public static Entity Floor(IntVector3D Pos)
{
return Floor(Pos.X, Pos.Y, Pos.Z);
}
public static Entity Snake(IntVector3D Pos)
{
return Snake(Pos.X, Pos.Y, Pos.Z);
}
public static Entity Wall(IntVector3D Pos)
{
return Wall(Pos.X, Pos.Y, Pos.Z);
}
public static Entity Player(IntVector3D Pos)
{
return Player(Pos.X, Pos.Y, Pos.Z);
}
public static Entity Door(IntVector Pos)
{
return Door((Pos, 1));
}
public static Entity Floor(IntVector Pos)
{
return Floor((Pos, 0));
}
public static Entity Snake(IntVector Pos)
{
return Snake((Pos,1));
}
public static Entity Wall(IntVector Pos)
{
return Wall((Pos,1));
}
public static Entity Player(IntVector Pos)
{
return Player((Pos, 1));
}
}
}