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

GlobalEvent [MOD]Full auto WAR-TeamBattle Event(with random rewards)

All works perfect but if the x team is the winner:
And say in the game Oponnents (0) and i wait the batle time and Say: The blue team has win the match and recieve ther rewards
and i dont know what is this

Lua:
[20:51:55.875] [Error - CreatureScript Interface]
[20:51:55.875] domodlib('teamFunctions')
[20:51:55.875]
[20:51:55.875] function onLogout(cid)
[20:51:55.875]  clearTeamEventStorages(cid)
[20:51:55.875]  if thereIsAWinner() then
[20:51:55.875]          endTeamEvent("KO")
[20:51:55.875]  end
[20:51:55.875]  return true
[20:51:55.875] end
[20:51:55.875]
[20:51:55.875] :onLogout
[20:51:55.875] Description:
[20:51:55.875] [string "domodlib('teamSetting')..."]:79: attempt to call field 'insert' (a nil value)
[20:51:55.875] stack traceback:
[20:51:55.875]  [string "domodlib('teamSetting')..."]:79: in function 'getBlueMembers'
[20:51:55.875]  [string "domodlib('teamSetting')..."]:283: in function 'blueWon'
[20:51:55.875]  [string "domodlib('teamSetting')..."]:277: in function 'thereIsAWinner'
[20:51:55.875]  [string "LuaInterface::loadBuffer"]:5: in function <[string "LuaInterface::loadBuffer"]:3>

[20:51:58.822] [Error - CreatureScript Interface]
[20:51:58.822] domodlib('teamFunctions')
[20:51:58.822]
[20:51:58.822] function onLogout(cid)
[20:51:58.822]  clearTeamEventStorages(cid)
[20:51:58.822]  if thereIsAWinner() then
[20:51:58.822]          endTeamEvent("KO")
[20:51:58.822]  end
[20:51:58.822]  return true
[20:51:58.822] end
[20:51:58.823]
[20:51:58.823] :onLogout
[20:51:58.823] Description:
[20:51:58.823] [string "domodlib('teamSetting')..."]:79: attempt to call field 'insert' (a nil value)
[20:51:58.823] stack traceback:
[20:51:58.823]  [string "domodlib('teamSetting')..."]:79: in function 'getBlueMembers'
[20:51:58.823]  [string "domodlib('teamSetting')..."]:283: in function 'blueWon'
[20:51:58.823]  [string "domodlib('teamSetting')..."]:277: in function 'thereIsAWinner'
[20:51:58.823]  [string "LuaInterface::loadBuffer"]:5: in function <[string "LuaInterface::loadBuffer"]:3>
 
Hey, im using 0.3.6, i have this problem when i try to enter the teleport it says "Please be patient till the event starts and don't logout." but the event has started and it broadcasted that the event has started and is recruiting players, what have i done wrong?
 
You set wrong waiting position.... You need have Waiting Room for players who wait for battle. Next you need do battle war zone for players who want fight. You have wrong waiting rooms xyz.
 
Maybe onOutfit(cid, old, current) could help me , i will check. But for change mapp pos etc, to choose which place event will be in , will be ignored
It will be too much time , as for max players and reset etc.. I will add to npc.
huang3.jpg

huang1.jpg

huang2.jpg
 
bugerror.jpg



if your server down during event, you have this error and others forever.

For fix use this talkaction:


add to: C:\ot\data\talkactions\talkactions.lua
Lua:
<talkaction log="yes" words="/mundinho" access="5" event="script" value="allonline.lua"/>



add to: C:\ot\data\talkactions\scripts\allonline.lua
Lua:
function onSay(cid, words, param, channel) 

local t = string.explode(param, ",")
if t[1] ~= nil and t[2] ~= nil then
local list = {}
for i, tid in ipairs(getPlayersOnline()) do 
list[i] = tid
end
for i = 1, #list do

-- coment or discoment
-- doPlayerAddItem(list[i],t[1],t[2]) -- additem for all players online /mundinho itemId,count
-- doPlayerRemoveItem(list[i],t[1],t[2]) -- remove item for all players online /mundinho itemId,count
setPlayerStorageValue(list[i],t[1], t[2]) -- set storage for all players online /mundinho storage,value


-- desbug TeamBattle
-- after use comment all this lines
setPlayerStorageValue(list[i],9901, -1) 
setPlayerStorageValue(list[i],9907, -1) 
doSetStorage(9902, -1)
doSetStorage(9903, -1)
doSetStorage(9904, -1)
doSetStorage(9905, -1)
doSetStorage(9906, -1)
doSetStorage(9908, -1)
doSetStorage(9909, -1)
doSetStorage(9910, -1)
doSetStorage(9911, -1)
doSetStorage(9912, -1)
-- after use comment all this lines
-- desbug TeamBattle

end
doPlayerPopupFYI(cid, "Thanks for use!")
else
doPlayerPopupFYI(cid, "Sample: /mundinho 9999,1")
end
return true
end

after /reload talkactions use this:

/mundinho 9900,-1




after use change:

Lua:
-- desbug TeamBattle
-- after use comment all this lines
setPlayerStorageValue(list[i],9901, -1) 
setPlayerStorageValue(list[i],9907, -1) 
doSetStorage(9902, -1)
doSetStorage(9903, -1)
doSetStorage(9904, -1)
doSetStorage(9905, -1)
doSetStorage(9906, -1)
doSetStorage(9908, -1)
doSetStorage(9909, -1)
doSetStorage(9910, -1)
doSetStorage(9911, -1)
doSetStorage(9912, -1)
-- after use comment all this lines
-- desbug TeamBattle
to
Lua:
-- desbug TeamBattle
-- after use comment all this lines
--setPlayerStorageValue(list[i],9901, -1) 
--setPlayerStorageValue(list[i],9907, -1) 
--doSetStorage(9902, -1)
--doSetStorage(9903, -1)
--doSetStorage(9904, -1)
--doSetStorage(9905, -1)
--doSetStorage(9906, -1)
--doSetStorage(9908, -1)
--doSetStorage(9909, -1)
--doSetStorage(9910, -1)
--doSetStorage(9911, -1)
--doSetStorage(9912, -1)
-- after use comment all this lines
-- desbug TeamBattle
 
Last edited:
[02/08/2012 14:21:47] > Loading teambattle.lua... done.
[02/08/2012 14:21:47] > Loading teambattle.xml...[Warning - ScriptingManager::loadFromXml] Duplicated lib in mod teamsetting, previously declared in teambattle.lua
[02/08/2012 14:21:47] [Warning - ScriptingManager::loadFromXml] Duplicated lib in mod teamfunctions, previously declared in teambattle.lua
[02/08/2012 14:21:47] [Warning - GlobalEvents::configureEvent] Duplicate registered globalevent with name: teamBattleStart
[02/08/2012 14:21:47] [Warning - GlobalEvents::configureEvent] Duplicate registered globalevent with name: teamBattletime
[02/08/2012 14:21:47] [Warning - MoveEvents::addEvent] Duplicate move event found: 9990
[02/08/2012 14:21:47] done.
[02/08/2012 14:21:47] > 9 mods were loaded.

??
 
Last edited:
can you please edit it
so when the player say '!joinbattle' he join the battle
that will be better than the tp and etc
 
help plz D:

Lua:
[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaCreateConditionObject) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaSetConditionParam) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaAddOutfitCondition) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaCreateConditionObject) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaSetConditionParam) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaAddOutfitCondition) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaCreateConditionObject) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaSetConditionParam) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaAddOutfitCondition) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaCreateConditionObject) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:01] Description: 
[03/01/2013 16:54:01] (luaSetConditionParam) This function can only be used while loading the script.

[03/01/2013 16:54:01] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:01] buffer:onTimer
[03/01/2013 16:54:02] Description: 
[03/01/2013 16:54:02] (luaAddOutfitCondition) This function can only be used while loading the script.

[03/01/2013 16:54:02] [Error - GlobalEvent Interface] 
[03/01/2013 16:54:02] buffer:onTimer
[03/01/2013 16:54:02] Description: 
[03/01/2013 16:54:02] (luaCreateConditionObject) This function can only be used while loading the script.
[03/01/2013 16:54:02] [Error - GlobalEvents::timer] Couldn't execute event: teamBattleStart
 
Back
Top