Jump to content

PedRotation don't work


SoiiNoob

Recommended Posts

Client

function Peds () 
mafia = createPed ( 111, 0, 0, 0 ) 
setElementInterior (mafia , 10, 1994.0821533203, 1017.4099121094, 994.890625 ) 
setPedVoice(mafia, "PED_TYPE_DISABLED") 
setPedFrozen (mafia , true ) 
setElementDimension (mafia , 0) 
end 
addEventHandler('onClientResourceStart', getResourceRootElement(), Peds) 

http://img813.imageshack.us/img813/1262/mtascreen20120303210717.png

I tryed a lot of things but it keeps dont working :S

Tryed

createPed ( model, x, y, z, RotX, RotY, RotZ ) 

setElementRotation(localname,rotX,rotY,rotZ) 

setPedRotation (localname,rotZ) 

Link to comment
function Peds () 
    mafia = createPed (111, 0, 0, 0, 0) -- Last '0' is the rotation. 
    setElementInterior (mafia, 10, 1994.0821533203, 1017.4099121094, 994.890625 ) 
    setPedVoice (mafia, "PED_TYPE_DISABLED") 
    setElementFrozen (mafia, true) 
    setElementDimension (mafia, 0) 
end 
addEventHandler("onClientResourceStart", resourceRoot, Peds) 

The ped spawns with no problems here.

Link to comment
createPed ( model, x, y, z, RotX, RotY, RotZ ) 

Read the wiki.

For example

createPed ( 50, 1.5, 2.5, 3.6, 0 ) -- 0 is rotation in grades 

0 the ped will look to the north of San andreas. you need turn. If you want the peed looking to the south

need change the rot to "90"

And that depend to where you want to turn the ped.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...