mirror of
https://github.com/vegapnk/RJW-Genes.git
synced 2024-08-15 00:23:31 +00:00
Added an Unbreakable Gene
This commit is contained in:
parent
75891ca0b3
commit
8e63e69385
6 changed files with 136 additions and 7 deletions
|
@ -10,8 +10,6 @@ namespace RJW_Genes
|
|||
/// </summary>
|
||||
public class Gene_Elasticity : Gene
|
||||
{
|
||||
|
||||
private int ticksToReset = RESET_INTERVAL;
|
||||
private const int RESET_INTERVAL = 60000; // 60k should be 1 day
|
||||
|
||||
public override void PostAdd()
|
||||
|
@ -26,11 +24,8 @@ namespace RJW_Genes
|
|||
public override void Tick()
|
||||
{
|
||||
base.Tick();
|
||||
--this.ticksToReset;
|
||||
if (this.ticksToReset > 0)
|
||||
return;
|
||||
this.ticksToReset = RESET_INTERVAL;
|
||||
ResetSeverity();
|
||||
if (pawn.IsHashIntervalTick(RESET_INTERVAL))
|
||||
ResetSeverity();
|
||||
}
|
||||
|
||||
public override void PostRemove()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue