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

Stat system

Nekiro

Excellent OT User
TFS Developer
Support Team
Joined
Sep 7, 2015
Messages
2,132
Best answers
94
Reaction score
991
This system was originally written for @Lucifer by me long time ago, he paid for it and has full credits to it. He messaged me, that he won't use it anymore and wants to release it.
He told me that I should do it, so I'm doing it.

This code was tested and does work with TFS 1.3, it should also work on any 1.x as long as all the interfaces needed are avaliable.

How does it work?
You enter which level you want to get points so you can choose between mana, hp & hit.
So every time you reach that level you get a point that you can put on hp / mana or attack 1 point = 1%
To add it to your server, just register all files to correct tfs interfaces, healthchange, advance and modal are creaturescripts, talkaction is talkaction. Point_stat_system is lib file, you add a dofile in main lib file in libs folder.

and that's it basically.

Enjoy!
 

Attachments

Marok

Excellent OT User
Joined
Jul 18, 2009
Messages
432
Best answers
0
Reaction score
653
Location
Jaraguá do Sul
that's different, and creative.

Its a little bit instable I guess, because people can make different combinations and cannot undo the choices, it can turn your game style disappointing in a point of view of you discovering a better combination of improvement, then your old choices are already done aaaand you need to create a new character or something like that.

And that combined with a needed of balance the spells (what point this system affect the heal, attacks and vocations balance? For an exemple).
 

William Hughes

New Member
Joined
Oct 12, 2018
Messages
28
Best answers
0
Reaction score
1
how to link the modalwindow in creaturescripts properly?

<event type="modalWindow" name="test" script="test/test.lua"/>
?

ending up with this error
 

Attachments

Last edited:

liqeen

Member
Joined
Nov 26, 2014
Messages
105
Best answers
0
Reaction score
5
how to link the modalwindow in creaturescripts properly?

<event type="modalWindow" name="test" script="test/test.lua"/>
?

ending up with this error
Creaturescripts
Code:
        <event type="healthchange" name="stat_system_healthchange" script="stat_system_healthchange.lua"/> 
        <event type="advance" name="stat_system_advance" script="stat_system_advance.lua"/> 
        <event type="modalwindow" name="stat_system_modal" script="stat_system_modal.lua"/>
Also have a one issue, the stats are working, command is working but when I assign point into damage for example, it just does not work, nothing happens after clicking the confirm button or enter. There is no any error in console what I am doing wrong @Nekiro ?
 

Tbol

Member
Joined
Apr 7, 2019
Messages
149
Best answers
0
Reaction score
19
It only have mana/hp/dmg? Those three? No def no spell dmg?
 
OP
Nekiro

Nekiro

Excellent OT User
TFS Developer
Support Team
Joined
Sep 7, 2015
Messages
2,132
Best answers
94
Reaction score
991
Updated the talkaction, player parameter was missing in modal call.
 

henkas

Active Member
Joined
Jul 8, 2015
Messages
725
Best answers
4
Reaction score
34
Invalid type for creature event: stat_system_modal
Failed to configure event.

So as far as i understand i have wrong <event type="modalwindow"
name but it suppose to be just fine, so it means ninja tfs 1.2 doesnt have modalwindow? If yes is there any ways to add it?
 
OP
Nekiro

Nekiro

Excellent OT User
TFS Developer
Support Team
Joined
Sep 7, 2015
Messages
2,132
Best answers
94
Reaction score
991
no, modal windows are supported since tibia 9.7
 

damian00912

New Member
Joined
Sep 11, 2009
Messages
43
Best answers
0
Reaction score
1
Lua Script Error: [TalkAction Interface]
data/talkactions/scripts/player/stat_system_talkaction.lua:eek:nSay
data/talkactions/scripts/player/stat_system_talkaction.lua:2: attempt to index global 'StatSystem' (a nil value)
stack traceback:
[C]: in function '__index'
data/talkactions/scripts/player/stat_system_talkaction.lua:2: in function <data/talkactions/scripts/player/stat_system_talkaction.lua:1>
 

Infernum

Support Team
Joined
Feb 14, 2015
Messages
5,492
Best answers
546
Reaction score
3,371
Lua Script Error: [TalkAction Interface]
data/talkactions/scripts/player/stat_system_talkaction.lua:eek:nSay
data/talkactions/scripts/player/stat_system_talkaction.lua:2: attempt to index global 'StatSystem' (a nil value)
stack traceback:
[C]: in function '__index'
data/talkactions/scripts/player/stat_system_talkaction.lua:2: in function <data/talkactions/scripts/player/stat_system_talkaction.lua:1>
You didn't install the lib file.
 
Top