Jump to content

Finish girl script problem?


Cheetah.dff

Recommended Posts

I created a script that I want to come out all right, but dancing girl winner in his car. How can I do it?

function pedcreation ( player ) 
        local x, y, z = getElementPosition ( player ) 
        local rot = getPedRotation ( player ) 
        peds = createPed (92, x, y, z + 2 , rot ) 
        setPedAnimation ( peds, "DANCING", "dnce_M_a") 
        attachElements ( peds, player ,0.5,2,1.5) 
            end 
  
  
addCommandHandler ( "piepie", pedcreation ) 
     
addEvent("onMapStarting") 
addEventHandler("onMapStarting", getRootElement(), 
function() 
destroyElement(peds) 
end) 

Link to comment
function pedcreation ( player ) 
            local x, y, z = getElementPosition ( player ) 
            local rot = getPedRotation ( player ) 
            peds = createPed (92, x, y, z + 2 , rot ) 
            attachElements ( peds, player ,0.5,2,1.5) 
            setPedAnimation ( peds, "DANCING", "dnce_M_a") 
                end 
      
      
    addCommandHandler ( "piepie", pedcreation ) 
        
    addEvent("onMapStarting") 
    addEventHandler("onMapStarting", getRootElement(), 
    function() 
    destroyElement(peds) 
    end) 

try this

And why are you using command handler? it makes this when you write in the command, only way it will work, so why you using it? just a question

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...