getPedClothes
Client-side
Server-side
Shared
Pair: addPedClothes
Manual Review Required
Please finish this page using the corresponding Old Wiki article. Go to Contribution guidelines for more information.
This function is used to get the current clothes texture and model of a certain type on a ped.
OOP Syntax Help! I don't understand this!
- Method: ped:getClothes(...)
Syntax
string, string getPedClothes ( ped thePed, int clothesType )Required Arguments
- thePed: The ped whose clothes you want to retrieve.
- clothesType: The type/slot of clothing you want to get.
Returns
- string: value1
- string: value2
This function returns 2 strings , the clothes texture and model. The first return value will be false if this player's clothes type is empty or an invalid player was specified.
Code Examples
shared
This example prints the model and texture of the current clothing on the player who enters the "clothes" command. For example: "clothes 3" for the shoes.
function getClothes ( source, key, clothesType ) local texture, model = getPedClothes ( source, clothesType ) if ( texture and model ) then outputChatBox ( getPlayerName(source) .. " is wearing " .. texture .. " " .. model .. " on his " .. getClothesTypeName(clothesType), source ) else outputChatBox ( "Invalid input.", source ) endendaddCommandHandler ( "clothes", getClothes )See Also
Ped Functions
- addPedClothes
- canPedBeKnockedOffBike
- createPed
- getPedAmmoInClip
- getPedAnalogControlState
- getPedAnimation
- getPedArmor
- getPedBonePosition
- getPedCameraRotation
- getPedClothes
- getPedContactElement
- getPedControlState
- getPedFightingStyle
- getPedGravity
- getPedMoveState
- getPedOccupiedVehicle
- getPedOccupiedVehicleSeat
- getPedOxygenLevel
- getPedSimplestTask
- getPedStat
- getPedTarget
- getPedTargetCollision
- getPedTargetEnd
- getPedTargetStart
- getPedTask
- getPedTotalAmmo
- getPedVoice
- getPedWalkingStyle
- getPedWeapon
- getPedWeaponMuzzlePosition
- getPedWeaponSlot
- getValidPedModels
- givePedWeapon
- isPedBleeding
- isPedChoking
- isPedDead
- isPedDoingGangDriveby
- isPedDoingTask
- isPedDucked
- IsPedFootBloodEnabled
- isPedHeadless
- isPedInVehicle
- isPedOnGround
- isPedReloadingWeapon
- isPedTargetingMarkerEnabled
- isPedWearingJetpack
- killPed
- playPedVoiceLine
- reloadPedWeapon
- removePedClothes
- removePedFromVehicle
- resetPedVoice
- setPedAimTarget
- setPedAnalogControlState
- setPedAnimation
- setPedAnimationProgress
- setPedAnimationSpeed
- setPedArmor
- setPedBleeding
- setPedCameraRotation
- setPedCanBeKnockedOffBike
- setPedChoking
- setPedControlState
- setPedDoingGangDriveby
- setPedEnterVehicle
- setPedExitVehicle
- setPedFightingStyle
- setPedFootBloodEnabled
- setPedGravity
- setPedHeadless
- setPedLookAt
- setPedOxygenLevel
- setPedStat
- setPedTargetingMarkerEnabled
- setPedVoice
- setPedWalkingStyle
- setPedWeaponSlot
- setPedWearingJetpack
- warpPedIntoVehicle