GetPedWalkingStyle: Difference between revisions
Jump to navigation
Jump to search
(New page: __NOTOC__ {{Server client function}} Returns the walking style ID of a ped. This ID determines the set of animations that is used during walking, running etc. ==Syntax== <syntaxhighlight lang="lua">int ge...) |
mNo edit summary |
||
(13 intermediate revisions by 7 users not shown) | |||
Line 1: | Line 1: | ||
__NOTOC__ | __NOTOC__ | ||
{{Server client function}} | {{Server client function}} | ||
Returns the walking style ID of a ped. This ID determines the set of animations that is used | {{New feature/item|3.0141|1.4.1|6945|Returns the walking style ID of a ped. This ID determines the set of animations that is used for walking, running etc.}} | ||
==Syntax== | ==Syntax== | ||
<syntaxhighlight lang="lua">int getPedWalkingStyle ( ped thePed )</syntaxhighlight> | <syntaxhighlight lang="lua">int getPedWalkingStyle ( ped thePed )</syntaxhighlight> | ||
{{OOP||[[Ped|ped]]:getWalkingStyle|walkingStyle|setPedWalkingStyle}} | |||
===Required Arguments=== | ===Required Arguments=== | ||
*'''thePed:''' the ped whose walking style to retrieve. | *'''thePed:''' the ped whose walking style to retrieve. | ||
Line 13: | Line 13: | ||
{{Ped walking styles}} | {{Ped walking styles}} | ||
==Example== | |||
<section name="Client" class="client" show="true"> | |||
<syntaxhighlight lang="lua"> | |||
addEventHandler("onClientResourceStart", resourceRoot, function() | |||
local style = getPedWalkingStyle(localPlayer) | |||
outputChatBox("Your walking style ID is " .. style) | |||
end) | |||
</syntaxhighlight> | |||
</section> | |||
==See Also== | ==See Also== | ||
{{Ped functions}} | {{Ped functions}} |
Latest revision as of 15:01, 24 July 2018
Returns the walking style ID of a ped. This ID determines the set of animations that is used for walking, running etc.
Syntax
int getPedWalkingStyle ( ped thePed )
OOP Syntax Help! I don't understand this!
- Method: ped:getWalkingStyle(...)
- Variable: .walkingStyle
- Counterpart: setPedWalkingStyle
Required Arguments
- thePed: the ped whose walking style to retrieve.
Returns
Returns the walking style ID if successful, false otherwise. The possible walking styles are as follows:
MOVE_DEFAULT | 0 |
MOVE_PLAYER | 54 |
MOVE_PLAYER_FAT | 55 |
MOVE_PLAYER_MUSCULAR | 56 |
MOVE_ROCKET | 57 |
MOVE_ROCKET_FAT | 58 |
MOVE_ROCKET_MUSCULAR | 59 |
MOVE_ARMED | 60 |
MOVE_ARMED_FAT | 61 |
MOVE_ARMED_MUSCULAR | 62 |
MOVE_BASEBALLBAT | 63 |
MOVE_BASEBALLBAT_FAT | 64 |
MOVE_BASEBALLBAT_MUSCULAR | 65 |
MOVE_CHAINSAW | 66 |
MOVE_CHAINSAW_FAT | 67 |
MOVE_CHAINSAW_MUSCULAR | 68 |
MOVE_SNEAK | 69 |
MOVE_JETPACK | 70 |
MOVE_MAN | 118 |
MOVE_SHUFFLE | 119 |
MOVE_OLDMAN | 120 |
MOVE_GANG1 | 121 |
MOVE_GANG2 | 122 |
MOVE_OLDFATMAN | 123 |
MOVE_FATMAN | 124 |
MOVE_JOGGER | 125 |
MOVE_DRUNKMAN | 126 |
MOVE_BLINDMAN | 127 |
MOVE_SWAT | 128 |
MOVE_WOMAN | 129 |
MOVE_SHOPPING | 130 |
MOVE_BUSYWOMAN | 131 |
MOVE_SEXYWOMAN | 132 |
MOVE_PRO | 133 |
MOVE_OLDWOMAN | 134 |
MOVE_FATWOMAN | 135 |
MOVE_JOGWOMAN | 136 |
MOVE_OLDFATWOMAN | 137 |
MOVE_SKATE | 138 |
Example
Click to collapse [-]
ClientaddEventHandler("onClientResourceStart", resourceRoot, function() local style = getPedWalkingStyle(localPlayer) outputChatBox("Your walking style ID is " .. style) end)
See Also
- addPedClothes
- getPedClothes
- removePedClothes
- createPed
- getPedAmmoInClip
- getPedArmor
- getPedFightingStyle
- getPedOccupiedVehicle
- getPedOccupiedVehicleSeat
- getPedStat
- getPedTarget
- getPedTotalAmmo
- getPedWalkingStyle
- getPedWeapon
- getPedWeaponSlot
- getPedContactElement
- getValidPedModels
- isPedChoking
- isPedDead
- isPedDoingGangDriveby
- isPedDucked
- isPedHeadless
- isPedInVehicle
- isPedOnFire
- isPedOnGround
- isPedWearingJetpack
- killPed
- removePedFromVehicle
- setPedAnimation
- setPedAnimationProgress
- setPedAnimationSpeed
- setPedArmor
- setPedDoingGangDriveby
- setPedFightingStyle
- setPedHeadless
- setPedOnFire
- setPedStat
- setPedWalkingStyle
- setPedWeaponSlot
- warpPedIntoVehicle