loop_server_timer and notice_in_map [PROBLEM]

04/09/2015 07:41 thenemne0032#1
Hey,

Code:
quest xxx begin
	state start begin
		when letter with pc.is_gm() begin
			send_letter("GM: Timer")
		end
		when info or button begin
			local sec = select("open","stop","close")
			if sec == 1 then 
				server_loop_timer("server1",3)
			elseif sec == 2 then
				clear_server_timer("server1")
			end
		end
		when server1.server_timer begin
				notice_in_map("XXX")
		end
	end
end
notice_in_map fails.

How do I run it? :(
04/09/2015 08:28 rollback#2
a servertimer cant do a notice_in_map
04/09/2015 08:34 thenemne0032#3
Quote:
Originally Posted by definitely not Sensenmann View Post
a servertimer cant do a notice_in_map
Thanks. Is there a cure?
04/09/2015 09:24 rollback#4
let it run on a pc with a eventflag

Code:
quest xxx begin
	state start begin
		when login with pc.get_map_index() == mapindex and game.get_event_flag("xx_time") < get_time() begin
			game.set_event_flag("xx_time", get_time()+60*3)
			notice_in_map("XXX")
		end
	end
end
this should work