Forum

> > CS2D > Scripts > entitylist gives back wrong list
Forums overviewCS2D overview Scripts overviewLog in to reply

English entitylist gives back wrong list

No replies
To the start Previous 1 Next To the start

old closed entitylist gives back wrong list

Edik
User Off Offline

Quote
Hello,
1
2
3
4
5
6
7
8
9
10
11
dirdebug = "sys/lua/debug/"
local file = io.open(dirdebug .. "debug.txt","w+")
local text = ""
local list=entitylist()
for _,e in pairs(list) do
	local v = "entity @ ("..e.x..","..e.y..") - "..entity(e.x,e.y,"typename")
	text = text .. tostring(v) .. "\n"
end
text = text:sub(1,-2)
file:write(text)
file:close()

this codes gives back a completely wrong list of entitys. If I open the map in Editor, I cant find the entity at the given coordinates.


Edit.: Solved. Wrong map was starting.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview