Newer
Older
DungeonShooting / DungeonShooting_Godot / src / game / activity / prop / buff / BuffProp0006.cs
@小李xl 小李xl on 9 Nov 2023 370 bytes 制作3个道具
  1.  
  2. using Godot;
  3.  
  4. /// <summary>
  5. /// 延长无敌时间buff, 受伤后无敌时间 + 2s
  6. /// </summary>
  7. [Tool]
  8. public partial class BuffProp0006 : BuffProp
  9. {
  10. public override void OnPickUpItem()
  11. {
  12. Master.RoleState.WoundedInvincibleTime += 2f;
  13. }
  14.  
  15. public override void OnRemoveItem()
  16. {
  17. Master.RoleState.WoundedInvincibleTime -= 2f;
  18. }
  19. }