DiosSasuke Posted April 22, 2018 Share Posted April 22, 2018 Hola, alguien me podria decir que hice malo en este script soy nuevo en esto ? En la consola me aparece server.lua:2: Bad argument @ `getElementPosition` [Expected element at argument 1, got nil] y Tambien me aparece server.lua:3: Bad argument @ `createexplosion` [Expected vector3 at argument 1, got boolean] function explosionOnSpawn ( ) local pX, pY, pZ = getElementPosition(source) createExplosion ( pX, pY, pZ, 6, source ) end addEventHandler ( "onPlayerSpawn", getRootElement(), explosionOnSpawn ) addCommandHandler ( "sharingan", explosionOnSpawn ) Link to comment
les26 Posted April 24, 2018 Share Posted April 24, 2018 function explosionOnSpawn (thePlayer) local pX, pY, pZ = getElementPosition(thePlayer) createExplosion ( pX, pY, pZ, 6, thePlayer ) end addEventHandler ( "onPlayerSpawn", getRootElement(), explosionOnSpawn ) addCommandHandler ( "sharingan", explosionOnSpawn ) Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now