Jump to content

ped script crash my GTA SA game!


BennyBunny

Recommended Posts

HI!

I have done a ped script and this script crash my GTA SA!

In the server log is no crash only a [Timed out ] when i get an error message from GTA SA.

This is the error message:

errorjay.jpg

And here is the part where make the crash:

function pedcheckweaponped1 ( attacker, weapon, thePlayer ) 
        local px,py,pz = getElementPosition( pedsex1 ) 
    if py > 2334 or py < 2332 then 
        setElementPosition ( pedsex1, 1214.2491699219, -4.9254320144653, 1000.6) 
    end 
    setElementHealth ( pedsex1, 1000 ) 
        setPedAnimation (pedsex1, "STRIP", "STR_C1", -1, true, true, true ) 
end 
addEventHandler ( "onClientPedDamage", getRootElement(), pedcheckweaponped1 ) 

IDK where is the problem here??

Link to comment

And here is my create ped script:

function pedsexparty1 () 
   pedsex1 = createPed(87, -2225.376953125, 2333.6584472656, 7.546875) 
   setPedAnimation (pedsex1, "STRIP", "STR_C1", -1, true, true, true ) 
   setPedRotation ( pedsex1, 10000 ) 
  
   pedsex2 = createPed(238, -2225.376953125, 2340.6584472656, 7.546875) 
   setPedAnimation (pedsex2, "STRIP", "STR_B2C", -1, true, true, true ) 
   setPedRotation ( pedsex2, 8000 ) 
end 
addEventHandler( "onClientResourceStart", getResourceRootElement(getThisResource()), pedsexparty1 ) 

I found out when i have only one ped is that no problem only 2+ crash my game!

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