• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Lua How to check if a player is under a roof or inside a building!

Printer

if Printer then print("LUA") end
Senator
Premium User
Joined
Dec 27, 2009
Messages
5,780
Solutions
31
Reaction score
2,300
Location
Sweden?
Hello everyone,

I wonder since i going to use a meteor spell. How to make that if they use the meteor spell inside a building or if there is a roof over that player. Either it doesnt shoot the spell or the effects should hit the roof!

Thanks! Rep!
 
Hm, How to check the tile below then? Also could you provide any example?
 
LUA:
local x = {123,345,678,901,234)
if isInArray(x,getThingFromPos({x=getCreaturePosition(cid).x, y=getCreaturePosition(cid).y, z=getCreaturePosition(cid).z, stackpos=0}).itemid) then
		--is on a roof
else
		--isn't on a roof
end
 
Well, it checks if the players on the roof. I want it to check if there something over the player :/ Sorry for misunderstanding me :/
 
Back
Top