internal PatternTypeDAO(DAO dao) { this.dao = dao; AllPatternTypes = Db.CreateCommand(); AllPatternTypes.CommandText = "SELECT id, north, south, west, east, textureid" + " FROM patterntype"; }
public PlayerDAO(DAO dao) { this.dao = dao; GetForClientCommand = Db.CreateCommand(); GetForClientCommand.CommandText = "SELECT id, nickname, hp, model, modelScaling, posX, posY, speed, texture" + " FROM Player" + " WHERE client=@client"; }
internal GameObjectDAO(DAO dao) { this.dao = dao; AllGameObjectsCommand = Db.CreateCommand(); AllGameObjectsCommand.CommandText = "SELECT id, posx, posy, posz, direction, model" + " FROM gameobjects"; }
public Server() { _startTime = DateTime.Now; //Network Setup PacketMap.Initialize(); _listener = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp); _acceptEventArgs = new SocketAsyncEventArgs(); _acceptEventArgs.Completed += AcceptCompleted; DAO = new DAO(); //Init World World = new World(this); //Vars Init Clients = new ConcurrentDictionary<int, Client>(); }
public PatternGenerator(DAO dao) { _dao = dao; }
public PatternGenerator(DAO dao) { _dao = dao; _types = _dao.PatternTypeDAO.GetAllPatternTypes(); }