feature: boosted creature / reading staticdata from assets / bestiary races rework#1064
feature: boosted creature / reading staticdata from assets / bestiary races rework#1064mehah merged 28 commits intoopentibiabr:mainfrom
Conversation
046f0a4 to
e7f699d
Compare
Edition : Windows 11 Pro |
|
|
@dudantas @luanluciano93 @mehah build issue fixed |
kokekanon
left a comment
There was a problem hiding this comment.
test:
work boosted creature, and cyclopedia in 13.40
|
can i merge then? :) |
|
|
||
| -- check if race id is present in the staticdata | ||
| if raceData.raceId == 0 then | ||
| local msg = string.format("[%s] Creature with race id %s was not found.", fileName, data.creatureraceid) |
There was a problem hiding this comment.
Have you tested when the raceis not found? This will throw an error since data is not defined. @Zbizu
There was a problem hiding this comment.
it returns an empty struct
There was a problem hiding this comment.
it returns an empty struct
For me it was throwing an error saying data is nil...
haha
|
Have you tested on a 860 server? The bestiary and cyclopedia doesn't exists, but most of servers have the concept of boosted monsters.. I'm unable to make the creature appear in the bottommenu: Apparently m_monsterRaces is empty on protocol 860 @Zbizu I made it work for simple creatures (with specific look type) by setting outfit with |
|
@lucasoares |
| errorMessage = errorMessage .. | ||
| tr('Unable to load spr file, please place a valid spr in \'%s.spr\'', sprPath) | ||
| errorList[#errorList + 1] = tr('Unable to load spr file, please place a valid spr in \'%s.spr\'', sprPath) | ||
| end |
There was a problem hiding this comment.
there it needs g_things.loadStaticData for things that use spr/dat
you can customize your staticdata with the tool I provided: https://github.com/Zbizu/staticdata-json
Don't think this all is necessary. At least not for the creature boost feature to work. For me it's working now. I made my status API to return all necessary outfit data: And made the client compatible with a table response: I'm accepting when the race is not found, using the raceid (data) as a looktype (this will work only with looktype-specific creatures, not human outfit, for example) to also have a little more compatibility. |





Description
This PR is quite big, but it would be rather difficult to split these three as they are very closely related to each other.
The original intention was to display boosted creature, but this ended up being a tip of an iceberg - staticdata was not read from the client at all, once I got it working, I found out that data behind boosted creature does not flow properly. Once I fixed that, I found out that the outfits cannot display because the assets don't preload. So in short: a lot of refactoring was involved in order to get a small thing to work.
Summary of changes
Removed monster/boss list from cyclopedia utils.lua
This is a breaking change so I wrote a tool that allows converting staticdata between dat and json:
https://github.com/Zbizu/staticdata-json
There are two branches -
masterrepacks staticdata and branchsoundrepacks soundbanksType of change
How Has This Been Tested
I was testing the code while working on it.
There is some issue with outfits scaling, the one you may know from character list.
Boosted creatures display properly.
Charms assign properly.
Bosses display properly.
Bestiary entries display properly.
Bestiary search bar doesn't seem to do anything. This is due to the fact that the implementation was already incorrect prior to this PR.
Test Configuration:
Checklist