本文整理汇总了C#中StatType类的典型用法代码示例。如果您正苦于以下问题:C# StatType类的具体用法?C# StatType怎么用?C# StatType使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
StatType类属于命名空间,在下文中一共展示了StatType类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Mod
public Mod(StatType stat, ModifierType type, double value)
: this()
{
Stat = stat;
Type = type;
Value = value;
}
示例2: Create
public static Stat Create(StatType type)
{
GameObject obj = (GameObject) Instantiate(Resources.Load("GUI/StatsPanel/Stat"));
Stat stat = obj.GetComponent<Stat>();
stat.Init(type);
return stat;
}
示例3: Modifier
public Modifier(StatType stat, bool percent, float percentValue, short value)
{
Percent = percent;
PercentValue = percentValue;
Stat = stat;
Value = value;
}
示例4: Stat
public Stat(StatType type, double startingValue = 0.0, double mod = 0.0, double dep = 0.0)
{
this.Type = type;
modifier = mod;
depletion = dep;
basevalue = startingValue;
}
示例5: Item
public Item(GraphicsDeviceManager g, ContentManager c, int weapon, Vector2 startLoc, Vector2 playerDim)
{
graphics = g;
content = c;
dimensions = new Vector2(90, 120);
loc = new Vector2(startLoc.X - playerDim.X / 2, startLoc.Y - playerDim.Y / 3);
random = new Random();
if (weapon == 0)
{
LoadContent("Textures/ShortSwordWalk");
vitality = 0;
dexterity = 0;
intelligence = 0;
strength = 0;
critBonus = 0;
critChance = 0;
minDmg = 1f;
maxDmg = 5f;
statType = StatType.str;
weaponType = WeaponType.slash;
atkSpd = 1f;
}
animation = new SpriteAnimation(8, itemSpriteSheet, .45, new Rectangle((int)loc.X, (int)loc.Y,
(int)dimensions.X, (int)dimensions.Y));
}
示例6:
public Stat this[StatType type]
{
get
{
return stats[type];
}
}
示例7: GetLevelByType
public int GetLevelByType( StatType type )
{
int returnInt = 0;
switch ( type )
{
case ( StatType.ShotPower ):
returnInt = shotPowerLevel;
break;
case ( StatType.ShieldLevel ):
returnInt = shieldLevel;
break;
case ( StatType.SpeedThrust ):
returnInt = speedThrustLevel;
break;
case ( StatType.ThrustDuration ):
returnInt = thrustDurationLevel;
break;
case ( StatType.LightRadius ):
returnInt = lightRadiusLevel;
break;
}
return returnInt + 1;
}
示例8: GetMeleeAPModByStat
public int GetMeleeAPModByStat(StatType stat)
{
if (m_MeleeAPModByStat == null)
{
return 0;
}
return m_MeleeAPModByStat[(int)stat];
}
示例9: GetRangedAPModByStat
public int GetRangedAPModByStat(StatType stat)
{
if (m_RangedAPModByStat == null)
{
return 0;
}
return m_RangedAPModByStat[(int)stat];
}
示例10: SetMeleeAPModByStat
public void SetMeleeAPModByStat(StatType stat, int value)
{
if (m_MeleeAPModByStat == null)
{
m_MeleeAPModByStat = new int[(int)StatType.End];
}
m_baseStats[(int)stat] = value;
this.UpdateMeleeAttackPower();
}
示例11: GetDateStatistics
public int[] GetDateStatistics(StatType statType, string subject)
{
List<StatType> stats = new List<StatType>();
stats.Add(statType);
Dictionary<StatType, int[]> retVal = GetDateStatistics(stats, subject);
return retVal[statType];
}
示例12: BlessEffect
public BlessEffect( StatType stat, int sound, int eid, int speed, int duraction, int eff, EffectLayer layer )
{
m_Stat = stat;
m_Snd = sound;
m_EffIID = eid;
m_EffSpd = speed;
m_Dur = duraction;
m_Eff = eff;
m_ELayer = layer;
}
示例13: PercentageStat
public PercentageStat(
string shortName,
string name,
string description,
string category,
string container,
StatType type,
Action<Stat> pullAction,
StatVerbosity verbosity)
: base(shortName, name, description, "%", category, container, type, pullAction, verbosity) {}
示例14: StatRecord
// more fields can be added (see in visualGGPK)
public StatRecord(Memory m, int addr)
{
Key = m.ReadStringU(m.ReadInt(addr + 0), 255);
Unknown4 = m.ReadByte(addr + 4) != 0;
Unknown5 = m.ReadByte(addr + 5) != 0;
Unknown6 = m.ReadByte(addr + 6) != 0;
Type = (StatType) m.ReadInt(addr + 7);
UnknownB = m.ReadByte(addr + 0xB) != 0;
UserFriendlyName = m.ReadStringU(m.ReadInt(addr + 0xC), 255);
}
示例15: updateStats
public void updateStats(StatType statType, int count)
{
int tmpCount = 0;
switch (statType)
{
case StatType.Input:
if (this.InvokeRequired)
{
this.submittedJobsLabel.Invoke(new Action<StatType, int>(updateStats), new object[] { statType, count });
}
lock (stateLock)
{
tmpCount = count;
}
this.submittedJobsLabel.Text = tmpCount.ToString();
break;
case StatType.Inprocess:
if (this.InvokeRequired)
{
this.inProcessJobsLabel.Invoke(new Action<StatType, int>(updateStats), new object[] { statType, count });
}
lock (stateLock)
{
tmpCount = count;
}
this.inProcessJobsLabel.Text = tmpCount.ToString();
break;
case StatType.Success:
if (this.InvokeRequired)
{
this.successJobsLabel.Invoke(new Action<StatType, int>(updateStats), new object[] { statType, count });
}
lock (stateLock)
{
tmpCount = count;
}
this.successJobsLabel.Text = tmpCount.ToString();
break;
case StatType.Failure:
if (this.InvokeRequired)
{
this.failedJobsLabel.Invoke(new Action<StatType, int>(updateStats), new object[] { statType, count });
}
lock (stateLock)
{
tmpCount = count;
}
this.failedJobsLabel.Text = count.ToString();
break;
}
}