View Single Post
03-02-24, 11:56 PM   #52
Hubb777
A Flamescale Wyrmkin
 
Hubb777's Avatar
AddOn Author - Click to view addons
Join Date: Jan 2024
Posts: 131
Originally Posted by Fizzlemizz View Post
Correct,

Lua Code:
  1. local Pets = someframe:CreateFontString(nil, somedrawlayer, somefont)

Replace someframe with the frame you want to be the parent of the new FontString
The parent will effect the Fonstrings scale and when it's, shown/hidden etc.

Replace somedrawlayer and somefont with the relevent information depending on where in the layer stack you want the string displayed and the font/size you want the text to be displayed in. See the docs for CreateFontString and see this page for some of the in-game fonts configurations ie. GameFontNormal, GameFontHighlight etc. etc. etc.

You can't use someframe (whichever that frame is) to create the FontString until after the frame itself has been created (The order that code is placed (runs) matters).
Hello. After several days I still couldn't figure it out (I'm stupid). I made the addon without these changes, it turned out pretty good.
https://www.wowinterface.com/downloa...o.php?id=26699
  Reply With Quote