MoveEvent "real tibia svargrond arena" for TFS 0.3.4 ver. 3

Status
Not open for further replies.

Gesior.pl

Mega Noob&LOL 2012
Joined
Sep 18, 2007
Messages
2,027
Best answers
19
Reaction score
1,071
Location
PLand
It work like RL tibia arena, not bugged like other scripts:
- max. 1 player in one room, max. 1 monster (full hp!) in one room
- second player can wait one room before (10 players in 10 rooms in same time!)
- kick after XX seconds in one room
- real tibia rewards from quest, create goblet when walk on tile (with name of player)
- 3 levels of arena, each with 10 monsters, all in 10 rooms
About script:
- use Unique IDs 42300 - 42400
- use PlayerStorage IDs 42300 - 42400
- use Action IDs 42300 - 42400
- use GlobalStorage IDS 42300 - 42500
1. Download file:
Map and scripts ver. 3 - english
or:
Map and scripts ver. 3 - polish
Unpack in 'OTS/data/' folder, it shouldn't overwrite any files.
2. In data/actions/actions.xml under:
PHP:
<actions>
Add:
PHP:
    <action actionid="42366" event="script" value="quests/arenadoors.lua"/>
    <action actionid="42376" event="script" value="quests/arenadoors.lua"/>
    <action actionid="42386" event="script" value="quests/arenadoors.lua"/>
    <action actionid="42357" event="script" value="quests/arenadoors.lua"/>
    <action fromaid="42361" toaid="42365" event="script" value="quests/arenareward.lua"/>
    <action fromaid="42371" toaid="42375" event="script" value="quests/arenareward.lua"/>
    <action fromaid="42381" toaid="42385" event="script" value="quests/arenareward.lua"/>
3. In data/movements/movements.xml under:
PHP:
<movements>
Add:
PHP:
    <movevent type="StepIn" actionid="42360" event="script" value="arenagoblet.lua"/>
    <movevent type="StepIn" actionid="42370" event="script" value="arenagoblet.lua"/>
    <movevent type="StepIn" actionid="42380" event="script" value="arenagoblet.lua"/>
    <movevent type="StepOut" actionid="42360" event="script" value="arenagoblet.lua"/>
    <movevent type="StepOut" actionid="42370" event="script" value="arenagoblet.lua"/>
    <movevent type="StepOut" actionid="42380" event="script" value="arenagoblet.lua"/>
    <movevent type="StepIn" fromaid="42300" toaid="42309" event="script" value="arenaroom.lua"/>
    <movevent type="StepIn" actionid="42310" event="script" value="didarenalevel.lua"/>
	<movevent type="StepIn" fromaid="42321" toaid="42330" event="script" value="leavearena.lua"/>
4. In data/lib/data.lua at end add:
PHP:
dofile(getDataDir() .. "lib/arena.lua")
5. In data/creaturescripts/creaturescripts.xml under:
PHP:
<event type="login" name="PlayerLogin" event="script" value="login.lua"/>
Add:
PHP:
<event type="kill" name="ArenaKill" event="script" value="arenakill.lua"/>
6. In data/creaturescripts/scripts/login.lua before:
PHP:
	return true
end
Add:
PHP:
	registerCreatureEvent(cid, "ArenaKill")
	-- if he did not make full arena 1 he must start from zero
	if getPlayerStorageValue(cid, 42309) < 1 then
		for i = 42300, 42309 do
			setPlayerStorageValue(cid, i, 0)
		end
	end
	-- if he did not make full arena 2 he must start from zero
	if getPlayerStorageValue(cid, 42319) < 1 then
		for i = 42310, 42319 do
			setPlayerStorageValue(cid, i, 0)
		end
	end
	-- if he did not make full arena 3 he must start from zero
	if getPlayerStorageValue(cid, 42329) < 1 then
		for i = 42320, 42329 do
			setPlayerStorageValue(cid, i, 0)
		end
	end
	if getPlayerStorageValue(cid, 42355) == -1 then
		setPlayerStorageValue(cid, 42355, 0) -- did not arena level
	end
	setPlayerStorageValue(cid, 42350, 0) -- time to kick 0
	setPlayerStorageValue(cid, 42352, 0) -- is not in arena
7. Open data/monster/monsters.xml and under:
PHP:
<monsters>
Add:
PHP:
	<!-- Arena -->
		<!-- Greenhorn -->
	<monster name="Achad" file="gesiorarena/greenhorn/achad.xml"/>
	<monster name="Axeitus Headbanger" file="gesiorarena/greenhorn/axeitus headbanger.xml"/>
	<monster name="Bloodpaw" file="gesiorarena/greenhorn/bloodpaw.xml"/>
	<monster name="Bovinus" file="gesiorarena/greenhorn/bovinus.xml"/>
	<monster name="Colerian The Barbarian" file="gesiorarena/greenhorn/colerian the barbarian.xml"/>
	<monster name="Cursed Gladiator" file="gesiorarena/greenhorn/cursed gladiator.xml"/>
	<monster name="Frostfur" file="gesiorarena/greenhorn/frostfur.xml"/>
	<monster name="Orcus the Cruel" file="gesiorarena/greenhorn/orcus the cruel.xml"/>
	<monster name="Rocky" file="gesiorarena/greenhorn/rocky.xml"/>
	<monster name="The Hairy One" file="gesiorarena/greenhorn/the hairy one.xml"/>

		<!-- Scrapper -->
	<monster name="Avalanche" file="gesiorarena/scrapper/avalanche.xml"/>
	<monster name="Drasilla" file="gesiorarena/scrapper/drasilla.xml"/>
	<monster name="Grimgor Guteater" file="gesiorarena/scrapper/grimgor guteater.xml"/>
	<monster name="Kreebosh the Exile" file="gesiorarena/scrapper/kreebosh the exile.xml"/>
	<monster name="Slim" file="gesiorarena/scrapper/slim.xml"/>
	<monster name="Spirit of Earth" file="gesiorarena/scrapper/spirit of earth.xml"/>
	<monster name="Spirit of Fire" file="gesiorarena/scrapper/spirit of fire.xml"/>
	<monster name="Spirit of Water" file="gesiorarena/scrapper/spirit of water.xml"/>
	<monster name="The Dark Dancer" file="gesiorarena/scrapper/the dark dancer.xml"/>
	<monster name="The Hag" file="gesiorarena/scrapper/the hag.xml"/>

		<!-- Warlord -->
	<monster name="Darakan the Executioner" file="gesiorarena/warlord/darakan the executioner.xml"/>
	<monster name="Deathbringer" file="gesiorarena/warlord/deathbringer.xml"/>
	<monster name="Fallen Mooh'tah Master Ghar" file="gesiorarena/warlord/fallen mooh'tah master ghar.xml"/>
	<monster name="Gnorre Chyllson" file="gesiorarena/warlord/gnorre chyllson.xml"/>
	<monster name="Norgle Glacierbeard" file="gesiorarena/warlord/norgle glacierbeard.xml"/>
	<monster name="Svoren the Mad" file="gesiorarena/warlord/svoren the mad.xml"/>
	<monster name="The Masked Marauder" file="gesiorarena/warlord/the masked marauder.xml"/>
	<monster name="The Obliverator" file="gesiorarena/warlord/the obliverator.xml"/>
	<monster name="The Pit Lord" file="gesiorarena/warlord/the pit lord.xml"/>
	<monster name="Webster" file="gesiorarena/warlord/webster.xml"/>
8. Open arena map ( data/world/Arena_map.otbm ), copy and paste somewhere on you map. Remember to change in data/lib/arena.lua:
PHP:
arenaKickPosition = {x=918, y=1240, z=6}
to your position.
Post bugs in this thread!
(maybe I forgot to post something)
 
Last edited:

furstwin

New Member
Joined
Aug 9, 2007
Messages
488
Best answers
0
Reaction score
1
Location
Sweden
First! :D Thanks alot gesior, good work as always, I will use it for sure ;)<3
 

Hermes

dziwki kola gramy w lola
Joined
Nov 17, 2007
Messages
1,867
Best answers
0
Reaction score
12
Location
Poland
Nice : p but I have already made it working with the newest distro :D
 

Vittyn

#Learning Linux
Joined
Nov 9, 2008
Messages
379
Best answers
0
Reaction score
12
Location
Brasil
Gesior, found this issues in console.
PHP:
[27/05/2009 11:45:25] Lua Script Error: [CreatureScript Interface] 
[27/05/2009 11:45:25] data/creaturescripts/scripts/login.lua

[27/05/2009 11:45:25] luaRegisterCreatureEvent(). Creature not found

[27/05/2009 11:45:25] Lua Script Error: [CreatureScript Interface] 
[27/05/2009 11:45:25] data/creaturescripts/scripts/login.lua

[27/05/2009 11:45:25] luaGetPlayerStorageValue(). Player not found

[27/05/2009 11:45:25] Lua Script Error: [CreatureScript Interface] 
[27/05/2009 11:45:25] data/creaturescripts/scripts/login.lua

[27/05/2009 11:45:25] data/creaturescripts/scripts/login.lua:23: attempt to compare boolean with number
[27/05/2009 11:45:25] [Warning - Event::loadScript] Cannot load script (data/creaturescripts/scripts/login.lua)
 

Vittyn

#Learning Linux
Joined
Nov 9, 2008
Messages
379
Best answers
0
Reaction score
12
Location
Brasil
Sorry Double - everybody knows ¬¬'
Gesior, everythings perfect, i get this because i read BEFORE and do AFTER
in logun.lua,
already fixed and now working fine' ;D
 

Vittyn

#Learning Linux
Joined
Nov 9, 2008
Messages
379
Best answers
0
Reaction score
12
Location
Brasil
Again i'm here, everythins working well, but something is wrong at
arenaroom.lua [ movements]
it does not summon monster for i kill,
but when i summon with /m and kill, its OK
look this,
PHP:
[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface] 
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:onStepIn

[27/05/2009 12:05:32] luaGetThingPos(). Thing not found

[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface] 
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:onStepIn

[27/05/2009 12:05:32] luaDoCreateMonster(). Cannot create monster: rocky

[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface] 
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:onStepIn

[27/05/2009 12:05:32] luaDoTeleportThing(). Thing not found
waiting fix :p
 

Wiw3K

New Member
Joined
Apr 16, 2008
Messages
371
Best answers
0
Reaction score
3
Again i'm here, everythins working well, but something is wrong at
arenaroom.lua [ movements]
it does not summon monster for i kill,
but when i summon with /m and kill, its OK
look this,
PHP:
[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface] 
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:onStepIn

[27/05/2009 12:05:32] luaGetThingPos(). Thing not found

[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface] 
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:onStepIn

[27/05/2009 12:05:32] luaDoCreateMonster(). Cannot create monster: rocky

[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface] 
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:onStepIn

[27/05/2009 12:05:32] luaDoTeleportThing(). Thing not found
waiting fix :p
same here...

i am using TFS 3.2
 

laxante

New Member
Joined
Mar 13, 2009
Messages
121
Best answers
0
Reaction score
3
Again i'm here, everythins working well, but something is wrong at
arenaroom.lua [ movements]
it does not summon monster for i kill,
but when i summon with /m and kill, its OK
look this,
PHP:
[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface] 
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:onStepIn

[27/05/2009 12:05:32] luaGetThingPos(). Thing not found

[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface] 
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:onStepIn

[27/05/2009 12:05:32] luaDoCreateMonster(). Cannot create monster: rocky

[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface] 
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:onStepIn

[27/05/2009 12:05:32] luaDoTeleportThing(). Thing not found
waiting fix :p

same error :/
 
OP
Gesior.pl

Gesior.pl

Mega Noob&LOL 2012
Joined
Sep 18, 2007
Messages
2,027
Best answers
19
Reaction score
1,071
Location
PLand
It's for 0.3.4. I don't know all bugs in engine from 0.3.2 and can't test. I fixed one bug. Download updated version (only data/movements/scripts/arenaroom.lua changed ) from first post (v2).
 

Stellow

C++/C#/PHP/LUA
Joined
Oct 23, 2008
Messages
1,022
Best answers
0
Reaction score
133
Location
Germany
i use tfs 0.3.4 and when i try do arena, show in console:
[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface]
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:eek:nStepIn

[27/05/2009 12:05:32] luaGetThingPos(). Thing not found

[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface]
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:eek:nStepIn

[27/05/2009 12:05:32] luaDoCreateMonster(). Cannot create monster: frostfut

[27/05/2009 12:05:32] Lua Script Error: [MoveEvents Interface]
[27/05/2009 12:05:32] data/movements/scripts/arenaroom.lua:eek:nStepIn

[27/05/2009 12:05:32] luaDoTeleportThing(). Thing not found

Obs: The monsters are ok!
 

Vittyn

#Learning Linux
Joined
Nov 9, 2008
Messages
379
Best answers
0
Reaction score
12
Location
Brasil
Gesior, when try to walk in TP to enter arena, its showing that in console
PHP:
[28/05/2009 15:13:49] Lua Script Error: [MoveEvents Interface] 
[28/05/2009 15:13:49] data/movements/scripts/arenaroom.lua:onStepIn

[28/05/2009 15:13:49] data/movements/scripts/arenaroom.lua:11: attempt to compare number with string
[28/05/2009 15:13:49] stack traceback:
[28/05/2009 15:13:49] 	data/movements/scripts/arenaroom.lua:11: in function <data/movements/scripts/arenaroom.lua:1>
i'll try to fix by myself, but' ;)
 

Vittyn

#Learning Linux
Joined
Nov 9, 2008
Messages
379
Best answers
0
Reaction score
12
Location
Brasil
i Just have deleted these lines
PHP:
			if monster_uid > 0 then
end
and script working perfect well' ;D
 

ranky

New Member
Joined
Apr 1, 2009
Messages
34
Best answers
0
Reaction score
1
Step 8

Hey Gesior, thank you for this great release, but
i dont realy understand step 8: with that change position,

which position must i change? the tp from last arena to the chest rooms or?...

please help me , thank you
 
Status
Not open for further replies.
Top