• 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!

CreatureEvent Advanced OnAdvance: The Best OnAdvance

I get this error

Code:
[07/05/2010 14:33:22] [Error - LuaScriptInterface::loadFile] data/creaturescripts/scripts/advanced.lua:20: '<eof>' expected near 'end'
[07/05/2010 14:33:22] [Warning - Event::loadScript] Cannot load script (data/creaturescripts/scripts/advanced.lua)
[07/05/2010 14:33:22] data/creaturescripts/scripts/advanced.lua:20: '<eof>' expected near 'end'

Using tfs 0.3.6pl1

how to fix?
 
I get this error

Code:
[07/05/2010 14:33:22] [Error - LuaScriptInterface::loadFile] data/creaturescripts/scripts/advanced.lua:20: '<eof>' expected near 'end'
[07/05/2010 14:33:22] [Warning - Event::loadScript] Cannot load script (data/creaturescripts/scripts/advanced.lua)
[07/05/2010 14:33:22] data/creaturescripts/scripts/advanced.lua:20: '<eof>' expected near 'end'
Using tfs 0.3.6pl1

how to fix?
you copypasted badly the script<_<
 
Added fancy edition to Main Post
 
is there also one for this script Like every 10 levels there comes a bigger effect :p
like level, 10,20,30,40,50,60 etc.

this one;

PHP:
--[[ / / / / / / / / / / / / / / / / / / / / / /
		Advanced OnAdvance Fancy Edition
	   The Best OnAdvance Creaturescript
			Scripted by Cybermaster
/ / / / / / / / / / / / / / / / / / / / / / ]]--
 
local area, data = 
{
	{0, 1, 1, 1, 0},
	{1, 1, 1, 1, 1},
	{1, 1, 1, 1, 1},
	{1, 1, 1, 1, 1},
	{0, 1, 1, 1, 0}
},
{
	[SKILL_FIST] = 'FISTUP!',
	[SKILL_CLUB] = 'CLUBUP!',
	[SKILL_SWORD] = 'SWORDUP!',
	[SKILL_AXE] = 'AXEUP!',
	[SKILL_DISTANCE] = 'DISTANCEUP!',
	[SKILL_SHIELD] = 'SHIELDUP!',
	[SKILL_FISHING] = 'FISHINGUP!',
	[SKILL__MAGLEVEL] = 'MAGICUP!',
	[SKILL__LEVEL] = 'LEVELUP!'
}
 
function onAdvance(cid, skill, oldLevel, newLevel)
    doPlayerSave(cid)
	local center, data = {}, data[skill] --function doSendMagicEffectInArea of Mock
    center.y = math.floor(table.getn(area)/2)+1
    for y = 1, table.getn(area) do
        for x = 1, table.getn(area[y]) do
            if area[y][x] > 0 then
                center.x = math.floor(table.getn(area[y])/2)+1
                doSendMagicEffect({x=getThingPos(cid).x+x-center.x,y=getThingPos(cid).y+y-center.y,z= getThingPos(cid).z},math.random(28,30),cid)
            end
        end
    end	
    for i = 1, #data do
		addEvent(doSendAnimatedText, i*150, getThingPos(cid), data:sub(i,i), i%2 == 0 and TEXTCOLOR_RED or TEXTCOLOR_ORANGE)
    end
    return true
end
 
This will definitely lag your server because of the database saving. These are the situations that will cause serious lag or freezing.

1) Multiple players level up at once. (including skill levels)
2) Too many level ups happen at once (even on just 1 player) I think most the time its 500+ (including skill levels)
3) If multiple players level up while on each others screens. The magic effects can cause client bugs. (Shouldn't cause debug)

As long as you are a lower rate server you are fine. If you plan on having "event monsters" be wary.
 
This will definitely lag your server because of the database saving. These are the situations that will cause serious lag or freezing.

1) Multiple players level up at once. (including skill levels)
2) Too many level ups happen at once (even on just 1 player) I think most the time its 500+ (including skill levels)
3) If multiple players level up while on each others screens. The magic effects can cause client bugs. (Shouldn't cause debug)

As long as you are a lower rate server you are fine. If you plan on having "event monsters" be wary.
4) one player with lots of items in equipment - this already happens when he logs in or out and is known problem of all engines
 
You won the Golden Shovel for this message !
Well, I'm grateful that is is still interesting after all these years : D

This will definitely lag your server because of the database saving. These are the situations that will cause serious lag or freezing.

1) Multiple players level up at once. (including skill levels)
2) Too many level ups happen at once (even on just 1 player) I think most the time its 500+ (including skill levels)
3) If multiple players level up while on each others screens. The magic effects can cause client bugs. (Shouldn't cause debug)

As long as you are a lower rate server you are fine. If you plan on having "event monsters" be wary.
Never heard of this before, aren't nowadays' computers and internet more efficient?
 
Back
Top