Turrets aren't built at the exact tile
2 replies



16.04.18 05:45:37 pm
Hello everyone,
I want just some help,
I'm not Scripter so i don't know about that but this script i had got by asking Unreal software, but it has some problem.
I have Check it & its Working, But When i Throw it So Turret Build on the Other side, Whereas at a exact tile Separate, where flare dropped.Why turret didn't build on exact tile where flare dropped.
Please Correct him for me.I want just where it will be drop so turret always make there place.
I want just some help,
I'm not Scripter so i don't know about that but this script i had got by asking Unreal software, but it has some problem.
Code:
addhook("projectile", "_p")
function _p(id, wpn, x, y)
if (wpn == 54) then
local team = player(id, "team")
parse("spawnobject 11 "..((x-16)/32).." "..((y-16)/32).." 0 0 "..team.." "..id)
end
end
function _p(id, wpn, x, y)
if (wpn == 54) then
local team = player(id, "team")
parse("spawnobject 11 "..((x-16)/32).." "..((y-16)/32).." 0 0 "..team.." "..id)
end
end
I have Check it & its Working, But When i Throw it So Turret Build on the Other side, Whereas at a exact tile Separate, where flare dropped.Why turret didn't build on exact tile where flare dropped.
Please Correct him for me.I want just where it will be drop so turret always make there place.
FRiendly boYy.
Admin/mod comment:
Don't choose generic titles for your topic please. Changed. /
Because your pixel-to-tile conversion formula is incorrect?
Try
Try
parse("spawnobject 11 "..math.floor(x/32).." "..math.floor(y/32).." 0 0 "..team.." "..id)





