Пример #1
0
        public void Test_38_RSI_Kind1()
        {
            byte[] source_bytes = File.ReadAllBytes("testdata/38/ItemInfo01.rsi");
            var    rsi          = new RM.v38.RSI(new ByteReader(source_bytes, ENC.KR));

            Assert.AreEqual(1, rsi.ItemKind);
            Assert.AreEqual(242, rsi.Items.Count);

            var item = rsi.Items[154];

            COMMON.IsNovaBlade(item);
            Assert.AreEqual("선 블레이드+2", item.ShopDescription);
            Assert.AreEqual("선 블레이드+1의 강화판", item.InventoryDescription);

            item = rsi.Items[164];
            COMMON.IsNovaWand(item);
            Assert.AreEqual("선 완드+3", item.ShopDescription);
            Assert.AreEqual("선 완드+2의 강화판", item.InventoryDescription);

            item = rsi.Items[146];
            COMMON.IsM9(item);
            Assert.AreEqual("바주카포+1", item.ShopDescription);
            Assert.AreEqual("바주카포의 강화판", item.InventoryDescription);

            COMMON.CompareFiles(source_bytes, rsi.Save(new ByteWriter(ENC.KR)));
        }
Пример #2
0
        public void Test_38_RMI_Kind4()
        {
            byte[] source_bytes = File.ReadAllBytes("testdata/38/Item04.rmi");
            var    rmi          = new RM.v38.RMI(new ByteReader(source_bytes));

            Assert.AreEqual(4, rmi.ItemKind);
            Assert.AreEqual(46, rmi.Items.Count);

            COMMON.IsGoldfish(rmi.Items[1]);
            COMMON.IsBeer(rmi.Items[22]);

            COMMON.CompareFiles(source_bytes, rmi.Save(new ByteWriter()));
        }
Пример #3
0
        public void Test_38_RMI_Kind1()
        {
            byte[] source_bytes = File.ReadAllBytes("testdata/38/Item01.rmi");
            var    rmi          = new RM.v38.RMI(new ByteReader(source_bytes));

            Assert.AreEqual(1, rmi.ItemKind);
            Assert.AreEqual(242, rmi.Items.Count);

            COMMON.IsNovaBlade(rmi.Items[154]);
            Assert.AreEqual(new CTF.Ref(4, 0, 42), rmi.Items[154].Message);

            COMMON.IsNovaWand(rmi.Items[164]);
            Assert.AreEqual(new CTF.Ref(4, 4, 26), rmi.Items[164].Message);

            COMMON.IsM9(rmi.Items[146]);
            Assert.AreEqual(new CTF.Ref(4, 5, 7), rmi.Items[146].Message);

            COMMON.CompareFiles(source_bytes, rmi.Save(new ByteWriter()));
        }