예제 #1
0
        public void run()
        {
            try
            {
                foreach (Coord coord in pathfinder.PathCollection())
                {
                    pathfinder.RoomObject().X        = coord.X;
                    pathfinder.RoomObject().Y        = coord.Y;
                    pathfinder.RoomObject().Rotation = RoomModelSql.CalculateRot(pathfinder.RoomObject().X, pathfinder.RoomObject().Y, pathfinder.RoomObject().GoalX, pathfinder.RoomObject().GoalY);

                    Thread.Sleep(500);

                    Message Response = new Message(1887);
                    Response.WriteInt32(1);
                    Response.WriteInt32(session.Habbo.id);
                    Response.WriteInt32(pathfinder.RoomObject().X);
                    Response.WriteInt32(pathfinder.RoomObject().X);
                    Response.WriteString("0.0");
                    Response.WriteInt32(pathfinder.RoomObject().Rotation);
                    Response.WriteInt32(pathfinder.RoomObject().Rotation);
                    Response.WriteString("/mv " + pathfinder.RoomObject().X + "," + pathfinder.RoomObject().X + ",0.0//");
                    session.SendPacket(Response);
                }
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
예제 #2
0
 public bool TryGetModel(string name, out RoomModelSql model)
 {
     return(RoomModels.TryGetValue(name, out model));
 }
예제 #3
0
 public bool TryGetModel(string name, out RoomModelSql model)
 {
     return RoomModels.TryGetValue(name, out model);
 }