Beispiel #1
0
        public static Player NewCharacter(byte gender, Job job, string name, SkinColor skinColor, object equips)
        {
            PlayerStats stats = PlayerStats.Default();

            List <SkillTab> skillTabs = new List <SkillTab>
            {
                new SkillTab(job)
            };

            return(new Player
            {
                SkillTabs = skillTabs,
                AccountId = AccountStorage.DEFAULT_ACCOUNT_ID,
                CharacterId = GuidGenerator.Long(),
                CreationTime = DateTimeOffset.UtcNow.ToUnixTimeSeconds() + AccountStorage.TickCount,
                Name = name,
                Gender = gender,
                Job = job,
                MapId = 52000065,
                Stats = stats,
                SkinColor = skinColor,
                Equips = (Dictionary <ItemSlot, Item>)equips,
                Motto = "Motto",
                HomeName = "HomeName",
                Coord = CoordF.From(-675, 525, 600) // Intro map (52000065)
            });
        }
Beispiel #2
0
        public static Player NewCharacter(byte gender, int job, string name, SkinColor skinColor, object equips)
        {
            PlayerStats stats = PlayerStats.Default();

            List <SkillTab> skillTabs = new List <SkillTab>
            {
                XmlParser.ParseSkills(job)
            };

            return(new Player
            {
                SkillTabs = skillTabs,
                AccountId = AccountStorage.DEFAULT_ACCOUNT_ID,
                CharacterId = GuidGenerator.Long(),
                CreationTime = DateTimeOffset.UtcNow.ToUnixTimeSeconds() + AccountStorage.TickCount,
                Name = name,
                Gender = gender,
                JobGroupId = job,
                Level = 1,
                MapId = 52000065,
                Stats = stats,
                SkinColor = skinColor,
                Equips = (Dictionary <ItemSlot, Item>)equips,
                Motto = "Motto",
                HomeName = "HomeName",
                Coord = CoordF.From(-675, 525, 600), // Intro map (52000065)
                GameOptions = new GameOptions(),
                Mesos = 10,
                Inventory = new Inventory(48),
                Mailbox = new Mailbox()
            });
        }
Beispiel #3
0
        public static Player Priest(long accountId, long characterId, string name = "Priest")
        {
            Job              job   = Job.Priest;
            PlayerStats      stats = PlayerStats.Default();
            StatDistribution statPointDistribution = new StatDistribution(totalStats: 18);
            List <SkillTab>  skillTabs             = new List <SkillTab>
            {
                new SkillTab(job)
            };

            Player player = new Player
            {
                SkillTabs             = skillTabs,
                StatPointDistribution = statPointDistribution,
                MapId       = 2000062,
                AccountId   = accountId,
                CharacterId = characterId,
                Name        = name,
                Gender      = 1,
                Motto       = "Motto",
                HomeName    = "HomeName",
                Coord       = CoordF.From(2850, 2550, 1800), // Lith Harbor (2000062)
                // Coord = CoordF.From(500, 500, 15000), // Tria
                Job       = job,
                SkinColor = new SkinColor()
                {
                    Primary = Color.Argb(0xFF, 0xEA, 0xBF, 0xAE)
                },
                CreationTime = DateTimeOffset.Now.ToUnixTimeSeconds() + Environment.TickCount,
                Equips       = new Dictionary <ItemSlot, Item> {
                    { ItemSlot.ER, Item.Ear() },
                    { ItemSlot.HR, Item.Hair() },
                    { ItemSlot.FA, Item.Face() },
                    { ItemSlot.FD, Item.FaceDecoration() }
                },
                Stats       = stats,
                GameOptions = new GameOptions(),
                Inventory   = new Inventory(48),
                Mailbox     = new Mailbox(),
                Stickers    = new List <short>
                {
                    1, 2, 3, 4, 5, 6, 7
                },
                TitleId    = 10000503,
                InsigniaId = 33,
                Titles     = new List <int> {
                    10000569, 10000152, 10000570, 10000171, 10000196, 10000195, 10000571, 10000331, 10000190,
                    10000458, 10000465, 10000503, 10000512, 10000513, 10000514, 10000537, 10000565, 10000602,
                    10000603, 10000638, 10000644
                },
                IsVIP = false,
            };

            player.Equips.Add(ItemSlot.RH, Item.DefaultScepter(player));
            player.Equips.Add(ItemSlot.LH, Item.DefaultCodex(player));
            return(player);
        }
Beispiel #4
0
        public static Player Char1(long accountId, long characterId, string name = "Char1")
        {
            int job = 50; // Archer

            PlayerStats      stats = PlayerStats.Default();
            StatDistribution StatPointDistribution = new StatDistribution();

            List <SkillTab> skillTabs = new List <SkillTab>
            {
                XmlParser.ParseSkills(job)
            };

            Player player = new Player
            {
                SkillTabs             = skillTabs,
                StatPointDistribution = StatPointDistribution,
                MapId       = 2000062,
                AccountId   = accountId,
                CharacterId = characterId,
                Level       = 70,
                Name        = name,
                Gender      = 1,
                Motto       = "Motto",
                HomeName    = "HomeName",
                Coord       = CoordF.From(2850, 2550, 1800), // Lith Harbor (2000062)
                // Coord = CoordF.From(500, 500, 15000), // Tria
                JobGroupId = job,
                SkinColor  = new SkinColor()
                {
                    Primary = Color.Argb(0xFF, 0xEA, 0xBF, 0xAE)
                },
                CreationTime = DateTimeOffset.Now.ToUnixTimeSeconds() + Environment.TickCount,
                Equips       = new Dictionary <ItemSlot, Item> {
                    { ItemSlot.ER, Item.Ear() },
                    { ItemSlot.HR, Item.Hair() },
                    { ItemSlot.FA, Item.Face() },
                    { ItemSlot.FD, Item.FaceDecoration() }
                },
                Stats       = stats,
                GameOptions = new GameOptions(),
                Mesos       = 200000,
                Merets      = 50,
                ValorToken  = 1,
                Treva       = 2,
                Rue         = 3,
                HaviFruit   = 4,
                MesoToken   = 5,
                Inventory   = new Inventory(48),
                Mailbox     = new Mailbox(),
                TitleId     = 10000292,
                InsigniaId  = 29
            };

            player.Equips.Add(ItemSlot.RH, Item.TutorialBow(player));
            return(player);
        }
Beispiel #5
0
        public static Player Default(long accountId, long characterId, string name = "SparkmodF")
        {
            int job = 10;

            PlayerStats stats = PlayerStats.Default();

            stats.Hp         = new PlayerStat(1000, 0, 1000);
            stats.CurrentHp  = new PlayerStat(0, 1000, 0);
            stats.Spirit     = new PlayerStat(100, 100, 100);
            stats.Stamina    = new PlayerStat(120, 120, 120);
            stats.AtkSpd     = new PlayerStat(120, 100, 130);
            stats.MoveSpd    = new PlayerStat(110, 100, 150);
            stats.JumpHeight = new PlayerStat(110, 100, 130);

            List <SkillTab> skillTabs = new List <SkillTab>();

            skillTabs.Add(XmlParser.ParseSkills(job));

            Player player = new Player
            {
                SkillTabs   = skillTabs,
                MapId       = 2000062,
                AccountId   = accountId,
                CharacterId = characterId,
                Level       = 70,
                Name        = name,
                Gender      = 1,
                Motto       = "Motto",
                HomeName    = "HomeName",
                Coord       = CoordF.From(2850, 2550, 1800), //Little Harbor
                //Coord = CoordF.From(500, 500, 15000), // tria
                JobGroupId = job,
                SkinColor  = new SkinColor()
                {
                    Primary = Color.Argb(0xFF, 0xEA, 0xBF, 0xAE)
                },
                CreationTime = DateTimeOffset.Now.ToUnixTimeSeconds(),
                Equips       = new Dictionary <ItemSlot, Item> {
                    { ItemSlot.ER, Item.Ear() },
                    { ItemSlot.HR, Item.Hair() },
                    { ItemSlot.FA, Item.Face() },
                    { ItemSlot.FD, Item.FaceDecoration() }
                },
                Stats       = stats,
                GameOptions = new GameOptions(),
                Mesos       = 10,
            };

            player.Equips.Add(ItemSlot.RH, Item.TutorialBow(player));
            return(player);
        }
Beispiel #6
0
        public static Player Char2(long accountId, long characterId, string name = "Char2")
        {
            int job = 50;

            PlayerStats stats = PlayerStats.Default();

            List <SkillTab> skillTabs = new List <SkillTab>
            {
                XmlParser.ParseSkills(job)
            };

            return(new Player
            {
                SkillTabs = skillTabs,
                MapId = 2000062,
                AccountId = accountId,
                CharacterId = characterId,
                Level = 70,
                Name = name,
                Gender = 0,
                Motto = "Motto",
                HomeName = "HomeName",
                Coord = CoordF.From(2850, 2550, 1800),
                JobGroupId = job,
                SkinColor = new SkinColor()
                {
                    Primary = Color.Argb(0xFF, 0xEA, 0xBF, 0xAE)
                },
                CreationTime = DateTimeOffset.Now.ToUnixTimeSeconds() + Environment.TickCount,
                Equips = new Dictionary <ItemSlot, Item> {
                    { ItemSlot.ER, Item.EarMale() },
                    { ItemSlot.HR, Item.HairMale() },
                    { ItemSlot.FA, Item.FaceMale() },
                    { ItemSlot.FD, Item.FaceDecorationMale() },
                    { ItemSlot.CL, Item.CloathMale() },
                    { ItemSlot.SH, Item.ShoesMale() },
                },
                Stats = stats,
                GameOptions = new GameOptions(),
                Mesos = 10,
                Inventory = new Inventory(48),
                Mailbox = new Mailbox()
            });
        }
Beispiel #7
0
        public static Player Char2(long accountId, long characterId, string name = "Char2")
        {
            Job         job   = Job.Archer;
            PlayerStats stats = PlayerStats.Default();

            List <SkillTab> skillTabs = new List <SkillTab>
            {
                new SkillTab(job)
            };

            return(new Player
            {
                SkillTabs = skillTabs,
                MapId = 2000062,
                AccountId = accountId,
                CharacterId = characterId,
                Name = name,
                Gender = 0,
                Motto = "Motto",
                HomeName = "HomeName",
                Coord = CoordF.From(2850, 2550, 1800),
                Job = job,
                SkinColor = new SkinColor()
                {
                    Primary = Color.Argb(0xFF, 0xEA, 0xBF, 0xAE)
                },
                CreationTime = DateTimeOffset.Now.ToUnixTimeSeconds() + Environment.TickCount,
                Equips = new Dictionary <ItemSlot, Item> {
                    { ItemSlot.ER, Item.EarMale() },
                    { ItemSlot.HR, Item.HairMale() },
                    { ItemSlot.FA, Item.FaceMale() },
                    { ItemSlot.FD, Item.FaceDecorationMale() },
                    { ItemSlot.CL, Item.CloathMale() },
                    { ItemSlot.SH, Item.ShoesMale() },
                },
                Stats = stats
            });
        }
Beispiel #8
0
        public static Player NewCharacter(byte gender, /*Job jobType*/ int job, string name, SkinColor skinColor, object equips)
        {
            PlayerStats stats = PlayerStats.Default();

            stats.Hp         = new PlayerStat(1000, 0, 1000);
            stats.CurrentHp  = new PlayerStat(0, 1000, 0);
            stats.Spirit     = new PlayerStat(100, 100, 100);
            stats.Stamina    = new PlayerStat(120, 120, 120);
            stats.AtkSpd     = new PlayerStat(120, 100, 130);
            stats.MoveSpd    = new PlayerStat(110, 100, 150);
            stats.JumpHeight = new PlayerStat(110, 100, 130);

            List <SkillTab> skillTabs = new List <SkillTab>();

            skillTabs.Add(XmlParser.ParseSkills(job));

            return(new Player
            {
                SkillTabs = skillTabs,
                AccountId = 0x1111111111111111,
                CharacterId = BitConverter.ToInt64(Guid.NewGuid().ToByteArray(), 0),
                CreationTime = DateTimeOffset.UtcNow.ToUnixTimeSeconds(),
                Name = name,
                Gender = gender,
                //jobType = jobType,
                JobGroupId = job,
                Level = 1,
                MapId = 2000062,
                Stats = stats,
                SkinColor = skinColor,
                Equips = (Dictionary <ItemSlot, Item>)equips,
                Motto = "Motto",
                HomeName = "HomeName",
                Coord = CoordF.From(2850, 2550, 1800),
                GameOptions = new GameOptions(),
                Mesos = 10,
            });
        }
Beispiel #9
0
        public static Player Default(long accountId, long characterId, int mapId, string name = "Default")
        {
            PlayerStats stats = PlayerStats.Default();

            stats.Hp         = new PlayerStat(1000, 0, 1000);
            stats.CurrentHp  = new PlayerStat(0, 1000, 0);
            stats.Spirit     = new PlayerStat(100, 100, 100);
            stats.Stamina    = new PlayerStat(120, 120, 120);
            stats.AtkSpd     = new PlayerStat(120, 100, 130);
            stats.MoveSpd    = new PlayerStat(110, 100, 150);
            stats.JumpHeight = new PlayerStat(110, 100, 130);

            return(new Player
            {
                MapId = mapId,//2000062,
                AccountId = accountId,
                CharacterId = characterId,
                Level = 80,
                Name = name,
                Gender = 1,
                Motto = "Motto",
                HomeName = "HomeName",
                Coord = CoordF.From(2850, 2550, 1800),
                JobGroupId = 50,
                SkinColor = new SkinColor()
                {
                    Primary = Color.Argb(0xFF, 0xEA, 0xBF, 0xAE)
                },
                CreationTime = DateTimeOffset.Now.ToUnixTimeSeconds(),
                Equip = new Dictionary <EquipSlot, Item> {
                },
                Stats = stats,
                GameOptions = new GameOptions(),
                Mesos = 10,
            });
        }
Beispiel #10
0
 public Npc(int id)
 {
     Id        = id;
     Animation = 255;
     stats     = PlayerStats.Default();
 }
Beispiel #11
0
        public static Player Char1(long accountId, long characterId, string name = "Char1")
        {
            Job              job   = Job.Archer;
            PlayerStats      stats = PlayerStats.Default();
            StatDistribution statPointDistribution = new StatDistribution(totalStats: 18);
            List <SkillTab>  skillTabs             = new List <SkillTab>
            {
                new SkillTab(job)
            };

            Player player = new Player
            {
                SkillTabs             = skillTabs,
                StatPointDistribution = statPointDistribution,
                MapId       = 2000062,
                AccountId   = accountId,
                CharacterId = characterId,
                Name        = name,
                Gender      = 1,
                Motto       = "Motto",
                HomeName    = "HomeName",
                Coord       = CoordF.From(2850, 2550, 1800), // Lith Harbor (2000062)
                // Coord = CoordF.From(500, 500, 15000), // Tria
                Job       = job,
                SkinColor = new SkinColor()
                {
                    Primary = Color.Argb(0xFF, 0xEA, 0xBF, 0xAE)
                },
                CreationTime = DateTimeOffset.Now.ToUnixTimeSeconds() + Environment.TickCount,
                Equips       = new Dictionary <ItemSlot, Item> {
                    { ItemSlot.ER, Item.Ear() },
                    { ItemSlot.HR, Item.Hair() },
                    { ItemSlot.FA, Item.Face() },
                    { ItemSlot.FD, Item.FaceDecoration() }
                },
                Stats    = stats,
                Stickers = new List <short>
                {
                    1, 2, 3, 4, 5, 6, 7
                },
                Emotes = new List <int>
                {
                    90200011, 90200004, 90200024, 90200041, 90200042,
                    90200057, 90200043, 90200022, 90200031, 90200005,
                    90200006, 90200003, 90200092, 90200077, 90200073,
                    90200023, 90200001, 90200019, 90200020, 90200021,
                    90200009, 90200027, 90200010, 90200028, 90200051,
                    90200015, 90200016, 90200055, 90200060, 90200017,
                    90200018, 90200093, 90220033, 90220012, 90220001, 90220033
                },
                TitleId    = 10000503,
                InsigniaId = 33,
                Titles     = new List <int> {
                    10000569, 10000152, 10000570, 10000171, 10000196, 10000195, 10000571, 10000331, 10000190,
                    10000458, 10000465, 10000503, 10000512, 10000513, 10000514, 10000537, 10000565, 10000602,
                    10000603, 10000638, 10000644
                }
            };

            player.Equips.Add(ItemSlot.RH, Item.TutorialBow(player));
            return(player);
        }
Beispiel #12
0
        public static Player Char1(
            long accountId,
            long characterId,
            string name     = "",
            int job         = 0,
            short level     = 0,
            byte gender     = 0,
            string motto    = "",
            string homename = "",
            long Mesos      = 0,
            long Merets     = 0,
            long ValorToken = 0,
            long Treva      = 0,
            long Rue        = 0,
            long HaviFruit  = 0,
            long MesoToken  = 0,
            short Storage   = 0)
        {
            PlayerStats stats = PlayerStats.Default();

            List <SkillTab> skillTabs = new List <SkillTab>();

            skillTabs.Add(XmlParser.ParseSkills(job));

            Player player = new Player
            {
                SkillTabs   = skillTabs,
                MapId       = 2000062,
                AccountId   = accountId,
                CharacterId = characterId,
                Level       = level,
                Name        = name,
                Gender      = gender,
                Motto       = motto,
                HomeName    = homename,
                Coord       = CoordF.From(2850, 2550, 1800), //Little Harbor
                //Coord = CoordF.From(500, 500, 15000), // tria
                JobGroupId = job,
                SkinColor  = new SkinColor()
                {
                    Primary = Color.Argb(0xFF, 0xEA, 0xBF, 0xAE)
                },
                CreationTime = DateTimeOffset.Now.ToUnixTimeSeconds() + Environment.TickCount,
                Equips       = new Dictionary <ItemSlot, Item> {
                    { ItemSlot.ER, Item.Ear() },
                    { ItemSlot.HR, Item.Hair() },
                    { ItemSlot.FA, Item.Face() },
                    { ItemSlot.FD, Item.FaceDecoration() }
                },
                Stats       = stats,
                GameOptions = new GameOptions(),
                Mesos       = Mesos,
                Merets      = Merets,
                ValorToken  = ValorToken,
                Treva       = Treva,
                Rue         = Rue,
                HaviFruit   = HaviFruit,
                MesoToken   = MesoToken,
                Inventory   = new Inventory(Storage),
                Mailbox     = new Mailbox()
            };

            player.Equips.Add(ItemSlot.RH, Item.TutorialBow(player));
            return(player);
        }
Beispiel #13
0
 public Npc(int id)
 {
     this.Id        = id;
     this.Animation = 255;
     this.stats     = PlayerStats.Default();
 }