• This is a read only backup of the old Emudevs forum. If you want to have anything removed, please message me on Discord: KittyKaev

[SOLVED] Question about item stats update only for player.

Status
Not open for further replies.

Vitrex

Moderator
Hello, all, today i woke up with one serious question does it's even possible in TC or 3.3.5a core make this :
I have item with entry 90000 which gives me + 500 stamina and i have upgrade token (with name + attack power token) i give it to NPC maybe gossip or smth and he he gives me same item but with + attack power 500 ? i mean add stats on items inside the game? this even possible? :D
 

FoxGaming

Exalted Member
I'm sure it's possible! I would take a look into the 3.3.5 reforge scripts, I'm sure with some minor adjustments that would work. I've often wanted to create a system like SWTOR where you can swap in and out modules but keep the gear the same, though a system like that would require so many modifications client side I've just stuck it on my dream list lol
 

Rochet2

Moderator / Eluna Dev
Completely possible.
However .. displaying changed stats is a problem.

Take a look at this:
https://youtu.be/eI2Sniiix8Y - possible
https://rochet2.github.io/?page=Reforging - "blizzlike" version

How my reforge scripts work: Same item however the specific item's stats are edited for the specific character.

The problem comes when I want to show the stats in tooltips.
Editing the tooltip only from server side requires you to either change the tooltip of all same entry items or then you have to always generate a new item, which would require a patch client side anyways for weapons and such if you dont want the effects of custom items ( cant use with spells .. has red question mark icon ,.. etc )
You could also try using enchants for this kind of things, but then you would probably need a client patch for the enchants and they would reserve enchant slots for the items.

My codes have an option to send the item packet to the player, however this means he sees all items with the same changes as his one item.
 
Last edited:

Rochet2

Moderator / Eluna Dev
How i understand the version like in video not shared , right?
P.s thanks.

Yes, but it was in unforgiven source which was leaked.
Thus the code is around the web somewhere, however I am not sharing it myself even though I have the full original patch file.
 

Rochet2

Moderator / Eluna Dev
Do note that it was made almost 3 years ago, so I suggest rather look at the blizzlike version and adapt that one.
Or just make a completely script and use the code parts. .. carefully or logic
 
Last edited:

Vitrex

Moderator
my core is Pre-update TC core ^.^
i think i can adapt that one old script ^.^
And one more question, that thing cannot be done by lua, only C++ script?
 

Rochet2

Moderator / Eluna Dev
my core is Pre-update TC core ^.^
i think i can adapt that one old script ^.^
And one more question, that thing cannot be done by lua, only C++ script?

Careful with it, the new patch is designed so it should also work fine with some adjustments on old core (before boost) since it doesnt actually use boost.
I try to use a few ways to avoid concurrency errors and locks these days.
At least check the commits on the blizzlike patch. https://github.com/TrinityCore/TrinityCore/compare/3.3.5...Rochet2:reforging

The way its done there cant be done with lua.
Lua might be capable of some workaround .. but anyways better not. (IE: anything is possible, but should you do it?)
The edits done are to the stat applying of an item on equip and unequip of an item.
 
Last edited:

Vitrex

Moderator
Big thanks to you, my hero ! :)
U solved my daily head pain on this question !
Because i have server idea on paper,in my head and plans and this is best fit my idea ! :)
 
Last edited:

Rochet2

Moderator / Eluna Dev
Big thanks to you, my hero ! :)
U solved my daily head pain on this question !
Because i have server idea on paper,in my head and plans and this is best fit my idea ! :)

How are you going to solve the issue of displaying stats on tooltips?
 

Vitrex

Moderator
Well, tbh i'm not right about that atm, for beginning i'll adopt script, then i'll think about tooltip ! :)
 
Status
Not open for further replies.
Top