Beispiel #1
0
 public BasePlante(EnumPlante _type) : base(0xF27)
 {
     Stackable = true;
     m_Plante  = _type;
     InitialTurn();
     Name = AgriHelper.GetPlanteString(m_Plante);
     UpdateLook();
 }
Beispiel #2
0
 public NubiaRecolte(EnumPlante plante, int roll, bool caneat) : base(8751)
 {
     Stackable    = true;
     m_canEat     = caneat;
     m_Plante     = plante;
     m_rollResult = roll;
     Name         = AgriHelper.GetPlanteString(m_Plante);
     ItemID       = AgriHelper.GetPlanteID(m_Plante, EnumPlanteState.Recolte);
 }
Beispiel #3
0
        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            int version = reader.ReadInt();

            m_Plante     = (EnumPlante)reader.ReadInt();
            m_rollResult = reader.ReadInt();
            m_canEat     = reader.ReadBool();
        }
Beispiel #4
0
        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            int version = reader.ReadInt();

            m_Plante     = (EnumPlante)reader.ReadInt();
            m_State      = (EnumPlanteState)reader.ReadInt();
            m_Tare       = (EnumPlanteTare)reader.ReadInt();
            m_rollResult = reader.ReadInt();
            m_turn       = reader.ReadInt();
        }
Beispiel #5
0
        public static Item GetRecolteItem(EnumPlante type)
        {
            switch (type)
            {
            case EnumPlante.Aqualide: return(new PlanteRecolteAqualide());

            case EnumPlante.Coton: return(new TissuCoton());

            case EnumPlante.Lin: return(new TissuLin());
            }
            return(null);
        }
Beispiel #6
0
        public static string GetPlanteString(EnumPlante type)
        {
            switch (type)
            {
            case EnumPlante.Ble: return("Blé");

            case EnumPlante.Marnok: return("Marnok");

            case EnumPlante.Citrouille: return("Citrouille");

            case EnumPlante.Aqualide: return("Aqualide");
            }
            return("inconue");
        }
Beispiel #7
0
        public static int GetPlanteID(EnumPlante type, EnumPlanteState state)
        {
            if (type == EnumPlante.Ble)
            {
                switch (state)
                {
                case EnumPlanteState.Recolte: return(4108);

                case EnumPlanteState.Graine: return(0xF27);

                case EnumPlanteState.GrainePlante: return(Utility.RandomList(7871, 7870));

                case EnumPlanteState.Naissante: return(3502);

                case EnumPlanteState.Jeune: return(3161);

                case EnumPlanteState.Mature: return(Utility.RandomList(3163, 3162));

                case EnumPlanteState.Pourri: return(3160);
                }
            }

            if (type == EnumPlante.Marnok)
            {
                switch (state)
                {
                case EnumPlanteState.Recolte: return(3200);

                case EnumPlanteState.Graine: return(0xF27);

                case EnumPlanteState.GrainePlante: return(0xF27);

                case EnumPlanteState.Naissante: return(15639);

                case EnumPlanteState.Jeune: return(15640);

                case EnumPlanteState.Mature: return(3197);

                case EnumPlanteState.Pourri: return(3197);
                }
            }

            if (type == EnumPlante.Citrouille)
            {
                switch (state)
                {
                case EnumPlanteState.Recolte: return(3178);

                case EnumPlanteState.Graine: return(3884);

                case EnumPlanteState.GrainePlante: return(3148);

                case EnumPlanteState.Naissante: return(Utility.RandomList(3188, 3189));

                case EnumPlanteState.Jeune: return(3180);

                case EnumPlanteState.Mature: return(Utility.RandomList(3178, 3179));

                case EnumPlanteState.Pourri: return(Utility.RandomList(3178, 3179));
                }
            }


            if (type == EnumPlante.Aqualide)
            {
                switch (state)
                {
                case EnumPlanteState.Recolte: return(15425);

                case EnumPlanteState.Graine: return(3884);

                case EnumPlanteState.GrainePlante: return(3148);

                case EnumPlanteState.Naissante: return(Utility.RandomList(15371, 15372));

                case EnumPlanteState.Jeune: return(Utility.RandomList(15406, 15407));

                case EnumPlanteState.Mature: return(Utility.RandomList(15433, 15434));

                case EnumPlanteState.Pourri: return(Utility.RandomList(15433, 15434));
                }
            }

            if (type == EnumPlante.Putralide)
            {
                switch (state)
                {
                case EnumPlanteState.Recolte: return(15481);

                case EnumPlanteState.Graine: return(3884);

                case EnumPlanteState.GrainePlante: return(3148);

                case EnumPlanteState.Naissante: return(Utility.RandomList(15426, 15427));

                case EnumPlanteState.Jeune: return(Utility.RandomList(15361, 15362));

                case EnumPlanteState.Mature: return(Utility.RandomList(15363, 15364));

                case EnumPlanteState.Pourri: return(Utility.RandomList(15363, 15364));
                }
            }

            if (type == EnumPlante.Coton)
            {
                switch (state)
                {
                case EnumPlanteState.Recolte: return(15481);

                case EnumPlanteState.Graine: return(3884);

                case EnumPlanteState.GrainePlante: return(3148);

                case EnumPlanteState.Naissante: return(Utility.RandomList(3155, 3156));

                case EnumPlanteState.Jeune: return(Utility.RandomList(3155, 3156));

                case EnumPlanteState.Mature: return(Utility.RandomList(3151, 3152));

                case EnumPlanteState.Pourri: return(Utility.RandomList(3151, 3152));
                }
            }

            if (type == EnumPlante.Lin)
            {
                switch (state)
                {
                case EnumPlanteState.Recolte: return(15481);

                case EnumPlanteState.Graine: return(3884);

                case EnumPlanteState.GrainePlante: return(3148);

                case EnumPlanteState.Naissante: return(Utility.RandomList(15446, 15447));

                case EnumPlanteState.Jeune: return(Utility.RandomList(15446, 15447));

                case EnumPlanteState.Mature: return(Utility.RandomList(15448, 15449));

                case EnumPlanteState.Pourri: return(Utility.RandomList(15448, 15449));
                }
            }


            return(0x28DD);
        }