Welcome to Ac-Web AC-Web

Join us now to get access to all our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, and so, so much more. It's also quick and totally free, so what are you waiting for?

Ask a Question

Ask Questions and Get Answers from Our Community

Ac-Web Official Repacks !

Here you will find all our official repacks

Contact Us

Contact a Staff member if needed

Creating a new item flag (HEROIC DISPLAY)

Browller

Veteran
Veteran
joined: Feb 14, 2015
messages: 395
Reaction score: 18
Points: 18
Location: Browller
Credits: 15
All credits to Grymskvll this was so helpful to me, maybe to some other too

To add a custom tooltip line for Epic difficulty items, you need to make some changes to Wow.exe (or alternatively do some Lua tooltip modding).

This is for WotLK 3.3.5 12340

Backup your Wow.exe.

Also, this probably requires that you've already patched Wow.exe to load custom interface files.

Open up notepad and copy this over:
PHP:
OFFSET_1 = 
OFFSET_2 = 
OFFSET_3 = 
OFFSET_4 = 
OFFSET_5 = 
OFFSET_6 =

Open Wow.exe in Ollydbg
Right click, search for -> All referenced strings
In the strings window, hit ctrl+f and find "ITEM_HEROIC".
Double click it and it'll take you to something that looks like this (the addresses might be slightly different):

PHP:
00627BA3      F641 18 08               TEST BYTE PTR DS:[ECX+18],08
00627BA7      74 24                    JE SHORT 00627BCD
00627BA9  |> /56                       PUSH ESI
00627BAA  |. |6A FF                    PUSH -1
00627BAC  |. |68 4866A200              PUSH OFFSET 00A26648         ; ASCII "ITEM_HEROIC"
00627BB1  |> |E8 8A211F00              CALL 00819D40
00627BB6  |. |83C4 0C                  ADD ESP,0C
00627BB9  |. |56                       PUSH ESI
00627BBA  |. |68 402DAD00              PUSH OFFSET 00AD2D40
00627BBF  |. |68 402DAD00              PUSH OFFSET 00AD2D40
00627BC4  |> |56                       PUSH ESI
00627BC5  |. |50                       PUSH EAX
00627BC6  |> |8BCF                     MOV ECX,EDI
00627BC8  |. |E8 F382FFFF              CALL 0061FEC0              ; Wow.0061FEC0
00627BCD  |> |3975 F0                  CMP DWORD PTR SS:[EBP-10],ESI

Right click the first "PUSH ESI" line (2 higher than the line with the ASCII comment), Edit->Copy address
Paste the address after OFFSET_1 in Notepad
Do the same for "CALL 00819D40" as OFFSET_2
Do the same for "CMP DWORD PTR SS:[EBP-10],ESI" as OFFSET_3

Now scroll to the bottom where you just see a bunch of lines that say "DB 00" (you can press Page Up/Down to advance one page at a time).
Pick a nice empty spot with 60 empty bytes. I chose 009DE3C0
Write down the address you choose as OFFSET_4
Calculate OFFSET_4 + 0x13 (http://www.miniwebtool.com/hex-calculator/), write it down as OFFSET_5.
Calculate OFFSET_4 + 0x24, write it down as OFFSET_6
Starting at your OFFSET_4, enter these lines, replacing OFFSET_# with your addresses:

PHP:
TEST BYTE PTR DS:[ECX+18],01
JE SHORT OFFSET_5
PUSH ESI
PUSH -1
PUSH OFFSET_6
JMP OFFSET_2
TEST BYTE PTR DS:[ECX+18],08
JE OFFSET_3
JMP OFFSET_1

Press ctrl+G and go to OFFSET_6.
Right click the highlighted line, go to Edit -> Binary edit
Put your cursor at the leftmost place in the HEX field, right click and paste this (make sure "Keep size" is UNCHECKED):

PHP:
49 54 45 4D 5F 48 45 52 4F 49 43 5F 45 50 49 43
5F 43 55 53 54 4F 4D 00 00 00 00

This will turn into ASCII "ITEM_HEROIC_EPIC_CUSTOM", which will be the name of our global Lua variable that holds the string we want to show in the tooltip.

Select all the red lines, right click -> Edit -> Copy to executable.
Don't close the popup, minimize it or drag it to the side so you can still find it.

Go back to the main window.
Press ctrl+G and go to OFFSET_1.
Select the two lines above it that say "TEST..." and "JE SHORT..."
Right click, Edit->Fill with NOPs
Then, with the red NOP lines still selected press space to edit them to:

PHP:
JMP OFFSET_4
NOP

Select these 2 red lines, right click -> Edit -> Copy to executable.

Now go to the popup from before, right click -> Save to file...
Choose a name you'll recognize, like Wow_tooltip_test.exe.
Close OllyDbg.

Next you just need to add a string for ITEM_HEROIC_EPIC_CUSTOM to GlobalStrings.lua

Extract the most up-to-date GobalStrings.lua from your game archives (or if you've already modified it, grab your modified one).
Open GlobalStrings.lua, search for "ITEM_HEROIC_EPIC".
Under it, add this line, replacing the string with whatever you like

PHP:
ITEM_HEROIC_EPIC_CUSTOM = "Epic Dungeon loot";

Save and pack into a custom MPQ or load it straight from WowInterfaceFrameXML

Finally, to create an item with this new tooltip line, set the 0x01 flag for the item in world.item_template.
If you're changing an existing item, remember to delete your client cache (WowcacheWDB).

If you don't know how to change the flag properly, take the old "flags" value from your world.item_template item row, convert to hex, add 0x01, convert back to decimal and enter it back into your database.

A warning is due, though. The 0x01 flag isn't used and its purpose is unknown, but it's possible that it will interfere with something. If the mod works but it crashes at a (random?) point, or has some other weird behavior, let me know. If this happens and you want to try to fix it, check documentation for the "flags" field in world.item_template and see which other flags are unused. You'll need to modify the condition we added for the 0x01 flag and update item flags.


iCUUyw2.jpg

https://i.imgur.com/iCUUyw2.jpg
PS: in this SS i named my custom flag to Titanforged.
 

XxTryXx

Senior
Pu
joined: Mar 7, 2014
messages: 1,202
Reaction score: 29
Points: 48
Location: http://strong-wow.com
Credits: 205
Lol gj
 
Last edited:

Breezicreaf

Registered
joined: Dec 17, 2012
messages: 83
Reaction score: 5
Points: 8
Credits: 10
Very nice guide sir. This is something i spend hours figuring out myself in the past, having a guide of this would of reduced the time spend by a lot. Thank you very much for this, i hope other people will find it useful!
 

Darksoke

Power User
Spu
joined: May 5, 2011
messages: 2,090
Reaction score: 118
Points: 63
Location: https://thoriumwow.net
Website obscountdown.com
Credits: 243
Holy shit the myth was broken, after so many years Thank you very much for the tut and here’s some REP for you


Just a small edit you mist add the new flag in core enums related to item flags
 
Last edited:

Browller

Veteran
Veteran
joined: Feb 14, 2015
messages: 395
Reaction score: 18
Points: 18
Location: Browller
Credits: 15
Thanks guys, good to seem it was helpful for others :), i'll share a tuto for custom class soon, keep looking...

- - - Updated - - -

Holy shit the myth was broken, after so many years Thank you very much for the tut and here’s some REP for you


Just a small edit you mist add the new flag in core enums related to item flags

Thanks for rep bro, so about the core changes, i didn't added it and worked aswell, when i done the .exe edits, just got the heroic flag id 8+0x01 = 9 (this is the new custom flag id)
 
Last edited:

Senix

Veteran
Veteran
joined: Feb 8, 2015
messages: 310
Reaction score: 18
Points: 0
Location: Noggit Level Designer
Credits: 0
good job dude!
 

teryaki1

Registered
joined: Aug 31, 2011
messages: 8
Reaction score: 0
Points: 1
Credits: 5
This is going to be a huge necro, but I just got this to work! And, I was able to add color to the text as well, as seen in the screenshot.

I have a question though, if you are still around. If I was to add a third affix along side the "Heroic" and first custom one, do I just add 0x02 to my flags to see it? I will test out doing so tomorrow but dont have the time to do it at the moment. Thanks

K9xEUfW.jpg
 

KsiOn

Registered
joined: Jan 28, 2021
messages: 1
Reaction score: 0
Points: 1
Credits: 5

Finally, to create an item with this new tooltip line, set the 0x01 flag for the item in world.item_template.
If you're changing an existing item, remember to delete your client cache (WowcacheWDB).

If you don't know how to change the flag properly, take the old "flags" value from your world.item_template item row, convert to hex, add 0x01, convert back to decimal and enter it back into your database.

A warning is due, though. The 0x01 flag isn't used and its purpose is unknown, but it's possible that it will interfere with something. If the mod works but it crashes at a (random?) point, or has some other weird behavior, let me know. If this happens and you want to try to fix it, check documentation for the "flags" field in world.item_template and see which other flags are unused. You'll need to modify the condition we added for the 0x01 flag and update item flags.


Tell someone where to add for this flags , I can't understand
 
Last edited:
Back
Top