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

TFS A* Algorithm :D

We reviewed this with @johnsamir via discord. He's now running his server with all the changes, was very easy to apply them all so I think he's not going to have more issues related to this system.

About the creature corner thing, we reproduced it on both engines, and it is indeed, delaying a little bit when the creature is on corners. But I also logged in to Tibia cipsoft (tibia rl) and noticed that the creature behaviour is the same (it stays on the corner). This only make me think that requesting this "feature" of getting out too fast from corners, is not cipsoft behaviour and I can say than is a custom feature (probably from 0.4/other engines).

There's cases, such as Deers, where they prioritize the scape, so they're really intended to walk out from corners. So I still need to test more the behaviour on this cases. But at the moment everything seems right at least for me.

Also, something important to say, is that the "corner trap" from real tibia depends a lot of where the player is placed, and also, of how to scaping route is drawn. For example, when I see that an Orc Spearman has a clear path that is a straight line to bottom, it will stay stucked on the corner. Otherwise, if the scaping route has free SQM to the right, but, it is not a straight line to the right, the creature will take the right path.

This are very very very little details, so I will keep testing it and see what I can conclude on all this. But in resume, I don't think that your suggestion on changing goToFollowCreature is correct. If you wish to have those creatures behaving like that, it's ok, but I advice that all the "elses" that are delaying the monster response are there for a reason.

Regards! ^^
Oo interesting , but which commit is this that changes the behavior of cornered monsters?

I am almost at a point where i can start testing with monsters as i am changing everything xD
 
There's no way that someone can fix a thing that isn't properly checked. And with this I mean, you should at least record or provide a screenshot, of why you think it has and error, and how it should behave. Don't post the code, post the proof that the system is not working how it should. As I see there's no issue at all.



Sorry for the delay, this one needs to be merged too in order to make everything work well ^^
Good catch @iNux

While you're testing all this I suggest that you merge kondras statistics system Feature - [TFS 1.4] OTS statistics (C++/Lua/SQL) by kondra (https://otland.net/threads/tfs-1-4-ots-statistics-c-lua-sql-by-kondra.283717/), allowing you to perhaps adjust some codes related to path finding and other things that might perhaps take a lot of CPU / Memory.

I'm trying to implement it myself but have some struggles, I'll keep trying and if I succeed I'll post the changes here.
 
While you're testing all this I suggest that you merge kondras statistics system
A bit off topic, but maybe someone needs it to add stats to his server:

Yesterday I reset my Docker cache (alpine:3.15.0 with all libraries installed) and I could not compile TFS 1.4 with OTS Stats using Docker anymore.

So I've made TFS 1.4 with OTS Stats and some 1.5 changes to make it compile on Linux (alpine:3.19.0) and Windows (vcpkg) [include stats.h/tasks.h in different files and move definitions of OTS Stats createTask (and other functions) to tasks.h, to make it compile without error with 1.5 compiler configuration]:
How to make OTS Stats work with lambda functions (TFS 1.5):

On topic:
I'm planning to add custom 'monsters AI' to my version of 1.4. It will make monsters run a bit dumber (like on real Tibia) and it should use less CPU.
First I must prepare some tool to benchmark how it works with XXX players and XXXX monsters. It may take a while, last Python 'stresser' tool I have is for 8.60 protocol.
 
Back
Top