本文整理汇总了C#中Gear.WeaponBonusDamage方法的典型用法代码示例。如果您正苦于以下问题:C# Gear.WeaponBonusDamage方法的具体用法?C# Gear.WeaponBonusDamage怎么用?C# Gear.WeaponBonusDamage使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Gear
的用法示例。
在下文中一共展示了Gear.WeaponBonusDamage方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: RefreshSelectedGear
//.........这里部分代码省略.........
cboGearSleaze.Visible = false;
cboGearDataProcessing.Visible = false;
cboGearFirewall.Visible = false;
lblGearAttackLabel.Visible = false;
lblGearSleazeLabel.Visible = false;
lblGearDataProcessingLabel.Visible = false;
lblGearFirewallLabel.Visible = false;
}
if (objGear.MaxRating > 0)
{
_blnSkipRefresh = true;
if (objGear.MinRating > 0)
nudGearRating.Minimum = objGear.MinRating;
else if (objGear.MinRating == 0 && objGear.Name.Contains("Credstick,"))
nudGearRating.Minimum = 0;
else
nudGearRating.Minimum = 1;
nudGearRating.Maximum = objGear.MaxRating;
nudGearRating.Value = objGear.Rating;
if (nudGearRating.Minimum == nudGearRating.Maximum)
nudGearRating.Enabled = false;
else
nudGearRating.Enabled = true;
_blnSkipRefresh = false;
}
else
{
_blnSkipRefresh = true;
nudGearRating.Minimum = 0;
nudGearRating.Maximum = 0;
nudGearRating.Enabled = false;
_blnSkipRefresh = false;
}
try
{
_blnSkipRefresh = true;
chkGearBlackMarketDiscount.Checked = objGear.DiscountCost;
//nudGearQty.Minimum = objGear.CostFor;
nudGearQty.Increment = objGear.CostFor;
nudGearQty.Value = objGear.Quantity;
_blnSkipRefresh = false;
}
catch
{
}
if (treGear.SelectedNode.Level == 1)
{
_blnSkipRefresh = true;
nudGearQty.Enabled = true;
nudGearQty.Increment = objGear.CostFor;
//nudGearQty.Minimum = objGear.CostFor;
chkGearEquipped.Visible = true;
chkGearEquipped.Checked = objGear.Equipped;
_blnSkipRefresh = false;
}
else
{
nudGearQty.Enabled = false;
_blnSkipRefresh = true;
chkGearEquipped.Visible = true;
chkGearEquipped.Checked = objGear.Equipped;
// If this is a Program, determine if its parent Gear (if any) is a Commlink. If so, show the Equipped checkbox.
if (objGear.IsProgram && _objOptions.CalculateCommlinkResponse)
{
Gear objParent = new Gear(_objCharacter);
objParent = objGear.Parent;
if (objParent.Category != string.Empty)
{
if (objParent.Category == "Commlinks" || objParent.Category == "Cyberdecks" || objParent.Category == "Nexus")
chkGearEquipped.Text = LanguageManager.Instance.GetString("Checkbox_SoftwareRunning");
}
}
_blnSkipRefresh = false;
}
// Show the Weapon Bonus information if it's available.
if (objGear.WeaponBonus != null)
{
lblGearDamageLabel.Visible = true;
lblGearDamage.Visible = true;
lblGearAPLabel.Visible = true;
lblGearAP.Visible = true;
lblGearDamage.Text = objGear.WeaponBonusDamage();
lblGearAP.Text = objGear.WeaponBonusAP;
}
else
{
lblGearDamageLabel.Visible = false;
lblGearDamage.Visible = false;
lblGearAPLabel.Visible = false;
lblGearAP.Visible = false;
}
treGear.SelectedNode.Text = objGear.DisplayName;
}
}
示例2: RefreshSelectedGear
//.........这里部分代码省略.........
chkActiveCommlink.Visible = false;
}
if (objGear.MaxRating > 0)
{
_blnSkipRefresh = true;
if (objGear.MinRating > 0)
nudGearRating.Minimum = objGear.MinRating;
else if (objGear.MinRating == 0 && objGear.Name.Contains("Credstick,"))
nudGearRating.Minimum = 0;
else
nudGearRating.Minimum = 1;
nudGearRating.Maximum = objGear.MaxRating;
nudGearRating.Value = objGear.Rating;
if (nudGearRating.Minimum == nudGearRating.Maximum)
nudGearRating.Enabled = false;
else
nudGearRating.Enabled = true;
_blnSkipRefresh = false;
}
else
{
_blnSkipRefresh = true;
nudGearRating.Minimum = 0;
nudGearRating.Maximum = 0;
nudGearRating.Enabled = false;
_blnSkipRefresh = false;
}
try
{
_blnSkipRefresh = true;
chkGearBlackMarketDiscount.Checked = objGear.DiscountCost;
//nudGearQty.Minimum = objGear.CostFor;
nudGearQty.Increment = objGear.CostFor;
nudGearQty.Value = objGear.Quantity;
_blnSkipRefresh = false;
}
catch
{
}
if (treGear.SelectedNode.Level == 1)
{
_blnSkipRefresh = true;
nudGearQty.Enabled = true;
nudGearQty.Increment = objGear.CostFor;
//nudGearQty.Minimum = objGear.CostFor;
chkGearEquipped.Visible = true;
chkGearEquipped.Checked = objGear.Equipped;
_blnSkipRefresh = false;
}
else
{
nudGearQty.Enabled = false;
_blnSkipRefresh = true;
chkGearEquipped.Visible = true;
chkGearEquipped.Checked = objGear.Equipped;
// If this is a Program, determine if its parent Gear (if any) is a Commlink. If so, show the Equipped checkbox.
if (objGear.IsProgram && _objOptions.CalculateCommlinkResponse)
{
Gear objParent = new Gear(_objCharacter);
objParent = objGear.Parent;
if (objParent.Category != string.Empty)
{
if (objParent.Category == "Commlink" || objParent.Category == "Nexus")
chkGearEquipped.Text = LanguageManager.Instance.GetString("Checkbox_SoftwareRunning");
}
}
_blnSkipRefresh = false;
}
// Show the Weapon Bonus information if it's available.
if (objGear.WeaponBonus != null)
{
lblGearDamageLabel.Visible = true;
lblGearDamage.Visible = true;
lblGearAPLabel.Visible = true;
lblGearAP.Visible = true;
lblGearDamage.Text = objGear.WeaponBonusDamage();
lblGearAP.Text = objGear.WeaponBonusAP;
}
else
{
lblGearDamageLabel.Visible = false;
lblGearDamage.Visible = false;
lblGearAPLabel.Visible = false;
lblGearAP.Visible = false;
}
if ((_objCharacter.Metatype.EndsWith("A.I.") || _objCharacter.MetatypeCategory == "Technocritters" || _objCharacter.MetatypeCategory == "Protosapients") && objGear.GetType() == typeof(Commlink))
{
chkGearHomeNode.Visible = true;
chkGearHomeNode.Checked = objGear.HomeNode;
}
treGear.SelectedNode.Text = objGear.DisplayName;
}
}
示例3: RefreshSelectedGear
//.........这里部分代码省略.........
{
lblGearDeviceRating.Text = objGear.DeviceRating.ToString();
chkActiveCommlink.Visible = false;
lblGearAttack.Visible = false;
lblGearSleaze.Visible = false;
lblGearDataProcessing.Visible = false;
lblGearFirewall.Visible = false;
lblGearAttackLabel.Visible = false;
lblGearSleazeLabel.Visible = false;
lblGearDataProcessingLabel.Visible = false;
lblGearFirewallLabel.Visible = false;
}
if (objGear.MaxRating > 0)
lblGearRating.Text = objGear.Rating.ToString();
else
lblGearRating.Text = "";
try
{
lblGearQty.Text = objGear.Quantity.ToString();
}
catch
{
}
if (treGear.SelectedNode.Level == 1)
{
_blnSkipRefresh = true;
lblGearQty.Text = objGear.Quantity.ToString();
chkGearEquipped.Visible = true;
chkGearEquipped.Checked = objGear.Equipped;
_blnSkipRefresh = false;
}
else
{
lblGearQty.Text = "1";
chkGearEquipped.Visible = true;
chkGearEquipped.Checked = objGear.Equipped;
// If this is a Program, determine if its parent Gear (if any) is a Commlink. If so, show the Equipped checkbox.
if (objGear.IsProgram && _objOptions.CalculateCommlinkResponse)
{
Gear objParent = new Gear(_objCharacter);
objParent = objGear.Parent;
if (objParent.Category != string.Empty)
{
if (objParent.Category == "Commlink" || objParent.Category == "Nexus")
chkGearEquipped.Text = LanguageManager.Instance.GetString("Checkbox_SoftwareRunning");
}
}
}
// Show the Weapon Bonus information if it's available.
if (objGear.WeaponBonus != null)
{
lblGearDamageLabel.Visible = true;
lblGearDamage.Visible = true;
lblGearAPLabel.Visible = true;
lblGearAP.Visible = true;
lblGearDamage.Text = objGear.WeaponBonusDamage();
lblGearAP.Text = objGear.WeaponBonusAP;
}
else
{
lblGearDamageLabel.Visible = false;
lblGearDamage.Visible = false;
lblGearAPLabel.Visible = false;
lblGearAP.Visible = false;
}
cmdGearReduceQty.Enabled = true;
if ((_objCharacter.Metatype.EndsWith("A.I.") || _objCharacter.MetatypeCategory == "Technocritters" || _objCharacter.MetatypeCategory == "Protosapients") && (objGear.GetType() == typeof(Commlink) || objGear.Category == "Nexus"))
{
chkGearHomeNode.Visible = true;
chkGearHomeNode.Checked = objGear.HomeNode;
}
treGear.SelectedNode.Text = objGear.DisplayName;
}
// Enable or disable the Split/Merge buttons as needed.
if (treGear.SelectedNode.Level == 1)
{
cmdGearSplitQty.Enabled = true;
cmdGearMergeQty.Enabled = true;
if (_objCharacter.Vehicles.Count > 0)
cmdGearMoveToVehicle.Enabled = true;
else
cmdGearMoveToVehicle.Enabled = false;
}
else
{
cmdGearSplitQty.Enabled = false;
cmdGearMergeQty.Enabled = false;
cmdGearMoveToVehicle.Enabled = false;
}
}
示例4: RefreshSelectedGear
//.........这里部分代码省略.........
chkGearHomeNode.Checked = objCommlink.HomeNode;
}
}
else
{
cboCyberwareGearOverclocker.Visible = _objCharacter.Overclocker;
lblCyberwareGearOverclocker.Visible = _objCharacter.Overclocker;
lblGearDeviceRating.Text = objGear.DeviceRating.ToString();
chkActiveCommlink.Visible = false;
cboGearAttack.Visible = false;
cboGearSleaze.Visible = false;
cboGearDataProcessing.Visible = false;
cboGearFirewall.Visible = false;
lblGearAttackLabel.Visible = false;
lblGearSleazeLabel.Visible = false;
lblGearDataProcessingLabel.Visible = false;
lblGearFirewallLabel.Visible = false;
}
if (objGear.MaxRating > 0)
lblGearRating.Text = objGear.Rating.ToString();
else
lblGearRating.Text = "";
try
{
lblGearQty.Text = objGear.Quantity.ToString();
}
catch
{
}
if (treGear.SelectedNode.Level == 1)
{
_blnSkipRefresh = true;
lblGearQty.Text = objGear.Quantity.ToString();
chkGearEquipped.Visible = true;
chkGearEquipped.Checked = objGear.Equipped;
_blnSkipRefresh = false;
}
else
{
lblGearQty.Text = "1";
chkGearEquipped.Visible = true;
chkGearEquipped.Checked = objGear.Equipped;
// If this is a Program, determine if its parent Gear (if any) is a Commlink. If so, show the Equipped checkbox.
if (objGear.IsProgram && _objOptions.CalculateCommlinkResponse)
{
Gear objParent = new Gear(_objCharacter);
objParent = objGear.Parent;
if (objParent.Category != string.Empty)
{
if (objParent.Category == "Commlink" || objParent.Category == "Nexus")
chkGearEquipped.Text = LanguageManager.Instance.GetString("Checkbox_SoftwareRunning");
}
}
}
// Show the Weapon Bonus information if it's available.
if (objGear.WeaponBonus != null)
{
lblGearDamageLabel.Visible = true;
lblGearDamage.Visible = true;
lblGearAPLabel.Visible = true;
lblGearAP.Visible = true;
lblGearDamage.Text = objGear.WeaponBonusDamage();
lblGearAP.Text = objGear.WeaponBonusAP;
}
else
{
lblGearDamageLabel.Visible = false;
lblGearDamage.Visible = false;
lblGearAPLabel.Visible = false;
lblGearAP.Visible = false;
}
cmdGearReduceQty.Enabled = true;
treGear.SelectedNode.Text = objGear.DisplayName;
}
// Enable or disable the Split/Merge buttons as needed.
if (treGear.SelectedNode.Level == 1)
{
cmdGearSplitQty.Enabled = true;
cmdGearMergeQty.Enabled = true;
if (_objCharacter.Vehicles.Count > 0)
cmdGearMoveToVehicle.Enabled = true;
else
cmdGearMoveToVehicle.Enabled = false;
}
else
{
cmdGearSplitQty.Enabled = false;
cmdGearMergeQty.Enabled = false;
cmdGearMoveToVehicle.Enabled = false;
}
}