Jump to content

Area Zone LS SF LV


MasterTobi

Recommended Posts

hey @ all

if have a Problem with createRadarArea

i created an Area like LS =createRadarArea (-905.5929,-2933.0986,4000,3500,255,255,255,100,source)

if I am in the area and type my Command /test then I get the expenditure "no"

LS =createRadarArea (-905.5929,-2933.0986,4000,3500,255,255,255,100,source)
function Zonen(source)
local posX, posY,posz = getElementPosition(source)
if (isInsideRadarArea(LS,posX, posY )) then
outputChatBox("jo")
else outputChatBox("nö")
end
end
addCommandHandler("test",Zonen)

if i press F11 to see the Map, i see the Area over LS and I am in the AREA

i need help, can somebody help me

sry for my bad english

Link to comment

1) Reading your code like that is a nightmare. Use [code=lua], space out your code a bit, and indent it properly.

2) As subenji said, that function doesn't really work on the server. However, you can just check the player's coordinates related to the radar area's in your own function, or you can create a colshape (colrectangle, in this case) in parallel with the radar area, and see if the player is within THAT.

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