• 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!
  • New resources must be posted under Resources tab. A discussion thread will be created automatically, you can't open threads manually anymore.

TalkAction deleted thread

Make it using onStatsChange, so you dont need to use a infinit addEvent loop and save RAM and CPU.

Good script =)
 
Make it using onStatsChange, so you dont need to use a infinit addEvent loop and save RAM and CPU.

Good script =)

Lua is fast enought to handle this without any significant ram/cpu usage.
 
Lua is fast enought to handle this without any significant ram/cpu usage.

Yes, but think about using alot of scripts in loop??
I have seen crashs because the server was using alot of loops not just in one script, but in many anothers, i mean if we can avoid it's better. =P
 
Yes, but think about using alot of scripts in loop??
I have seen crashs because the server was using alot of loops not just in one script, but in many anothers, i mean if we can avoid it's better. =P

I know what you mean, but I don't think server would crash because of my code, even if there were thousands of open events activated. But I'll try to make it using onStatsChange and maybe develop this code a bit further.
 
You are a good programmer.

Regards,
TibiaWR


If you're interested in joining a project (part-time or full-time), check out my signature.
 
#teckman
Conde2 was said true, use onStatsChange, because you add loop like while(true)do, and it can eat many ram if 100 players got use this heal bot and in 1 sec which run healbot player can die. ;)
 
#teckman
Conde2 was said true, use onStatsChange, because you add loop like while(true)do, and it can eat many ram if 100 players got use this heal bot and in 1 sec which run healbot player can die. ;)

I just tested it on 17 mc with 4 heals and nothing happened, so my guess is that it won't crash any server or cause any players to die because of a bug or sth. ;p
 
Lua is fast enought to handle this without any significant ram/cpu usage.

LUA can handle this without any significant ram/cpu usage. 'ok'

Maybe 600 playes online using the bot: LUA can't handle 600 inifinits loops per second without any significant ram/cpu usage.
 
LUA can handle this without any significant ram/cpu usage. 'ok'

Maybe 600 playes online using the bot: LUA can't handle 600 inifinits loops per second without any significant ram/cpu usage.

Actually it can, but I won't argue about that, because it has no sense to discuss this.
 
Back
Top