示例#1
0
        public readonly string description;         //= new char [1500];

        public itemTable(
            string _name            = "",
            char[] _flavor          = null,      // will warn if it is null
            string _callTitle       = "",
            short _frequency        = 0,
            short _marketValue      = 0,
            short _strengthRequired = 0,
            randomRange _range      = null,         // do nothing if null
            bool _identified        = false,
            bool _called            = false,
            string _description     = ""

            )
        {
            name   = _name;
            flavor = _flavor;
            if (flavor == null)
            {
                Debug.LogError("item flavor not initialized :" + name);
            }
            callTitle        = _callTitle;
            frequency        = _frequency;
            marketValue      = _marketValue;
            strengthRequired = _strengthRequired;
            range            = _range;
            identified       = _identified;
            called           = _called;
            description      = _description;
        }         // constructure
示例#2
0
        public creatureType(
            monsterTypes nMonsterID        = monsterTypes.MK_YOU,
            string _monsterName            = "", char _displayChar = ' ',
            color _foreColor               = null, // will warn if null
            short _maxHP                   = 0, short _defense = 0, short _accuracy = 0,
            randomRange _damage            = null, // do nothing if null
            long _turnsBetweenRegen        = 0,
            short _movementSpeed           = 0,
            short _attackSpeed             = 0,
            dungeonFeatureTypes _bloodType = (dungeonFeatureTypes)0,
            lightType _intrinsicLightType  = lightType.NO_LIGHT,
            short _DFChance                = 0,
            dungeonFeatureTypes _DFType    = (dungeonFeatureTypes)0,
            boltType [] _bolts             = null,    // it's ok, maybe
            ulong _flags                   = 0,
            ulong _abilityFlags            = 0

            )
        {
            monsterID   = (monsterTypes)nMonsterID;
            monsterName = _monsterName;
            displayChar = _displayChar;
            foreColor   = _foreColor;
            if (foreColor == null)
            {
                foreColor = Global.black;
                Debug.LogError("monster color not initialized : " + nMonsterID);
            }
            maxHP             = _maxHP;
            defense           = _defense;
            accuracy          = _accuracy;
            damage            = _damage;
            turnsBetweenRegen = _turnsBetweenRegen;
            movementSpeed     = _movementSpeed;
            attackSpeed       = _attackSpeed;

            bloodType          = _bloodType;
            intrinsicLightType = _intrinsicLightType;
            DFChance           = _DFChance;
            DFType             = _DFType;

            bolts = _bolts;
            if (bolts == null)
            {
                bolts = new boltType [20];
            }

            flags        = _flags;
            abilityFlags = _abilityFlags;
        } // constructure
示例#3
0
 public lightSource(
     color _lightColor          = null,
     randomRange _lightRadius   = null,            //  do nothing if null
     short _radialFadeToPercent = 0,
     bool _passThroughCreatures = false
     )
 {
     lightColor = _lightColor;
     if (lightColor == null)
     {
         lightColor = Global.black;
     }
     lightRadius          = _lightRadius;
     radialFadeToPercent  = _radialFadeToPercent;
     passThroughCreatures = _passThroughCreatures;
 } // constructure
示例#4
0
        }         // constructure

        public itemTable(
            string _name            = "",
            string _str_flavor      = null,          // will warn if it is null
            string _callTitle       = "",
            short _frequency        = 0,
            short _marketValue      = 0,
            short _strengthRequired = 0,
            randomRange _range      = null,         //  do nothing if null
            bool _identified        = false,
            bool _called            = false,
            string _description     = ""

            ) : this(_name,
                     _str_flavor != null ? _str_flavor.ToCharArray() : null,
                     _callTitle, _frequency, _marketValue,
                     _strengthRequired,
                     _range, _identified, _called, _description

                     )
        {
        } // constructure
示例#5
0
 public static short randClump(randomRange theRange)
 {
     return(randClumpedRange(theRange.lowerBound, theRange.upperBound, theRange.clumpFactor));
 }