Jump to content

[Help]BadArgumant and Boolean


Recommended Posts

[2018-07-10 14:19:03] WARNING: [gameplay]/yaratik/zombie_server.lua:320: Bad argument @ 'getElementPosition' [Expected element at argument 1]
[2018-07-10 14:19:03] WARNING: [gameplay]/yaratik/zombie_server.lua:321: Bad argument @ 'getElementPosition' [Expected element at argument 1]
[2018-07-10 14:19:03] WARNING: [gameplay]/yaratik/zombie_server.lua:322: Bad argument @ 'getDistanceBetweenPoints3D' [Expected vector3 at argument 1, got boolean]

 

ED3ApB.png

--CHECKS FOR ZOMBIE GRABBING FROM BEHIND
function Playerthroatbitten ( player, attacker)
	local Zx, Zy, Zz = getElementPosition( attacker )
	local Px, Py, Pz = getElementPosition( player )
	local distance = (getDistanceBetweenPoints3D( Px, Py, Pz, Zx, Zy, Zz ))
	if (distance < 1) then    ----323.dize
		killPed ( player, attacker, weapon, bodypart )
	else
		setPedAnimation (player)
	end
end

 

 

Edited by Yurigarga
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...