A PigPain: Difference between revisions
Jump to navigation
Jump to search
Content deleted Content added
Made this page |
Blue Shadow (talk | contribs) Corrected documentation |
||
| (7 intermediate revisions by 3 users not shown) | |||
| Line 1: | Line 1: | ||
{{codepointer|Hexen|Sound}}'''A_PigPain''' |
|||
'''A_Look''' |
|||
(no parameters) |
(no parameters) |
||
==Usage== |
|||
Plays the sound "PigPain", used by Hexen's [[Classes:Pig|Pig.]] |
|||
Plays the {{Property|PainSound|pain sound}} of the actor by calling {{c|[[A_Pain]]}} and thrusts it vertically in the air with a small force. The thrust is only applied if the actor is resting on the ground. |
|||
''[[Hexen]]'s'' {{Class|pig}} is currently the only actor class that makes use of this function. |
|||
== Examples == |
|||
This code is the equivalent of calling {{c|[[A_PigPain]]}}. |
|||
Pain: |
|||
EXAM A 2 |
|||
EXAM A 0 [[A_Pain]] |
|||
EXAM A 2 [[A_JumpIf]](z <= floorz, "Thrust") // See [[DECORATE expressions#Variables|DECORATE expressions]] |
|||
Goto See |
|||
Thrust: |
|||
EXAM A 2 [[A_ChangeVelocity]](velx, vely, 1.0 * 7 / 2, {{const|CVF_REPLACE}}) |
|||
Goto See |
|||
Latest revision as of 15:46, 22 April 2015
A_PigPain
(no parameters)
Usage
Plays the pain sound of the actor by calling A_Pain and thrusts it vertically in the air with a small force. The thrust is only applied if the actor is resting on the ground.
Hexen's pig is currently the only actor class that makes use of this function.
Examples
This code is the equivalent of calling A_PigPain.
Pain:
EXAM A 2
EXAM A 0 A_Pain
EXAM A 2 A_JumpIf(z <= floorz, "Thrust") // See DECORATE expressions
Goto See
Thrust:
EXAM A 2 A_ChangeVelocity(velx, vely, 1.0 * 7 / 2, CVF_REPLACE)
Goto See