• This is a read only backup of the old Emudevs forum. If you want to have anything removed, please message me on Discord: KittyKaev

Reload Timer Bug

Status
Not open for further replies.

Foereaper

Founder
As stated above, if you're talking about lua timed events, then this is completely intentional and not a bug :p reloading the engine dereference all pointers and events to not cause conflicts whenever the scripts are reloaded into memory :) also, if these weren't dereferenced, they would most likely cause memory leak issues
 

luzifix

Respected Member
i have a problem with this script, the script dont start the Timer but is load :(

Code:
print("---Time Events Loaded---");

local time_money_send = "Sat,18:00";

local function global_timer()
	local gtime = os.date("%a,%H:%M", GetGameTime());
	-- All 5 sec
	print("Test 123 - "..gtime);
	player_money_getplayer();
	
	if(gtime == time_money_send) then
		player_money_send(gtime);
		guild_money_send(gtime);
	end
end

CreateLuaEvent(global_timer, 5000, 0);
 

teroare

Enthusiast
I see there Saturday, 18:00 . Doesn't this mean you have to meet the conditions for it to work ?
Have you changed your OS time and date to Saturday to test ?
 

Foereaper

Founder
The timer is called no matter, and there's a print in there that should print every 5 seconds, however I believe his source is outdated
 

Rochet2

Moderator / Eluna Dev
It is indeed a bug.
And it actually only happens to global events that are running when you reload eluna :)

It has now been fixed.
 

Foereaper

Founder
It is indeed a bug.
And it actually only happens to global events that are running when you reload eluna :)

It has now been fixed.

It worked fine whenever we tested it when you fixed the last issue with it, also works fine on a build from yesterday :p
 

Rochet2

Moderator / Eluna Dev
Well, it didnt for me. (Before the fix)
Also, the bug fix was a work of logic, so testing doesnt matter.
:3

The events were set to be deleted on next tick on reload, but the next tick happens after the reload has finished.
The events remove themselves upon deletion from the system, and the new events used the same IDs as the old ones.
This caused the old events to remove the new events as well.
 
Status
Not open for further replies.
Top