예제 #1
0
파일: Program.cs 프로젝트: Illya9999/HISP
        static void Main(string[] args)
        {
            Console.Title = "HISP - Horse Isle Server Emulator";
            ConfigReader.OpenConfig();
            CrossDomainPolicy.GetPolicy();
            Database.OpenDatabase();
            GameDataJson.ReadGamedata();

            Map.OpenMap();
            World.ReadWorldData();
            Treasure.Init();

            DroppedItems.Init();
            WildHorse.Init();

            Drawingroom.LoadAllDrawingRooms();
            Brickpoet.LoadPoetryRooms();
            Multiroom.CreateMultirooms();

            Auction.LoadAllAuctionRooms();

            Item.DoSpecialCases();


            GameServer.StartServer();
        }
예제 #2
0
파일: Program.cs 프로젝트: KuromeSan/HISP
        static void Main(string[] args)
        {
        #if (!DEBUG)
            AppDomain.CurrentDomain.UnhandledException += new UnhandledExceptionEventHandler(CurrentDomain_UnhandledException);
        #endif

            Console.Title = ServerVersion.GetBuildString();
            ConfigReader.OpenConfig();
            CrossDomainPolicy.GetPolicy();
            Database.OpenDatabase();
            GameDataJson.ReadGamedata();

            Map.OpenMap();
            World.ReadWorldData();
            Treasure.Init();

            DroppedItems.Init();
            WildHorse.Init();

            Drawingroom.LoadAllDrawingRooms();
            Brickpoet.LoadPoetryRooms();
            Multiroom.CreateMultirooms();

            Auction.LoadAllAuctionRooms();

            Item.DoSpecialCases();

            GameServer.StartServer();

            while (true)
            {
            }
            ;
        }
예제 #3
0
        public void TestRide()
        {
            Debug.WriteLine("Riding horse...");
            Horse horse = new Horse();

            horse.Ride();

            Debug.WriteLine("Riding wild horse...");
            WildHorse wildHorse = new WildHorse();

            wildHorse.Ride();

            Debug.WriteLine("Treating wild horse as horse...");
            horse = wildHorse;
            horse.Ride();
        }
예제 #4
0
        public static bool CallHorse(string message, string[] args, User user)
        {
            if (!user.Administrator)
            {
                return(false);
            }

            string formattedmessage = Messages.FormatPlayerCommandCompleteMessage(message.Substring(1));

            WildHorse horse = WildHorse.WildHorses[GameServer.RandomNumberGenerator.Next(0, WildHorse.WildHorses.Length)];

            horse.X = user.X;
            horse.Y = user.Y;

            GameServer.UpdateAreaForAll(user.X, user.Y);

            byte[] chatPacket = PacketBuilder.CreateChat(formattedmessage, PacketBuilder.CHAT_BOTTOM_LEFT);
            user.LoggedinClient.SendPacket(chatPacket);
            return(true);
        }
예제 #5
0
        private void InitAnimals()
        {
            WildDuck  ducky       = new WildDuck("Ducky");
            WildCat   brizy       = new WildCat("Brizy");
            WildDog   rony        = new WildDog("Rony");
            WildHorse blackbeauty = new WildHorse("BlackBeauty");
            Zebra     sam         = new Zebra("Sam");
            Monkey    cip         = new Monkey("Cip");
            Elephant  dumbo       = new Elephant("Dumbo");
            Leopard   jack        = new Leopard("Jack");

            animals.Add(ducky);
            animals.Add(brizy);
            animals.Add(rony);
            animals.Add(blackbeauty);
            animals.Add(sam);
            animals.Add(cip);
            animals.Add(dumbo);
            animals.Add(jack);
        }