ID:264852
 
Code:
area
Click()
world<<"[src.x],[src.y]"


Problem description:

I ALWAYS get 1,1 when I click anywhere, I could have sworn it should give the right location? I dunno, How would I get the right location where I click?

I know turf/Click works, but Thats not what I'm trying to do. I have an area that overlays the turfs on my map, (area/Outside) it has a layer above everything, for a day/night system.
If you want the location you click, you either have to use a /turf, /obj, or /mob. There is only one instance of each individual area. If you have 500 tiles where you've designated /area/mountain, all 500 of those are represented by the same /area/mountain at runtime, so you can't use them for a specific location.

If you're relying on areas for location, then your hierarchies are probably wrong. /area should be the bottom level, with /turf objects on top of it, and /obj and /mob objects on top of the /turf objects. /obj and /mob objects on the map exist in the contents variables of /turf objects, and /turf objects on the map exist in the contents variables of /area objects.
In response to Kuraudo
Ah. I might as well explain myself, I'm doing a day and night system and I need area's to be above everything else so that when it becomes dark out, you see it. I'll show you the code for this system here:
area
outside
layer = 6
var
on = 1
proc
daytime()
on = 1 - on
if(on)
overlays -= 'darkA.dmi'
overlays += 'darkB.dmi'
sleep(3)
overlays -= 'darkA.dmi'
else
overlays += 'darkB.dmi'
sleep(3)
overlays -= 'darkA.dmi'
overlays += 'darkB.dmi'
spawn(300) daytime()

When its day day and there's no overlays on the area, turf/click works just fine, but the second it becomes dark out, turf clicking no longer works.
In response to King killer 113711
You need to set the area's mouse_opacity to 0 so that it can no longer be clicked. :O
In response to LordAndrew
Never thought of that..Hmm, I guess its been awhile since I've worked on coding :D Thanks Works :) Thank you. Happy Holidays.