Advertisement
Mudbill

Secret Wall Passage (Amnesia)

Apr 5th, 2013
690
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.67 KB | None | 0 0
  1. void InteractPassage(string &in asEntity)
  2. {
  3. int interactCount = GetLocalVarInt("HitCount");
  4.  
  5. AddLocalVarInt("HitCount", 1);
  6. AddTimer("", 0.5, "DecreaseHitCount");
  7.  
  8. CreateParticleSystemAtEntity("", "ps_dust_impact.ps", "AreaParticle_" + RandInt(1, 4), false);
  9.  
  10. if (interactCount == 3)
  11. {
  12. SetPropHealth("Passage", 0);
  13. }
  14.  
  15. if (GetTimerTimeLeft("limitsound") == 0)
  16. {
  17. AddTimer("limitsound", 0.5, "");
  18.  
  19. PlayGuiSound("impact_rock_low3.ogg", 1);
  20. PlayGuiSound("15_rock_break", 1);
  21. }
  22. }
  23.  
  24. void DecreaseHitCount(string &in asTimer)
  25. {
  26. AddLocalVarInt("HitCount", -1);
  27. }
  28.  
  29. void BreakWall(string &in asEntity, string &in type)
  30. {
  31. GiveSanityBoostSmall();
  32. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement