It looks like you're new here. If you want to get involved, click one of these buttons!
[AlphabetObject]
Graphic = AlphabetGraphic
Position = (310, 740, -0.1)
Group = titles
Color = (255, 0, 0)
Scale = 2
[AlphabetGraphic]
Pivot = top left
Text = AlphabetText
[AlphabetText]
Font = LCDFont
String = ABCDEF
alphabetObject = orxObject_CreateFromConfig("AlphabetObject");
orxGRAPHIC *graphic = orxGRAPHIC(orxOBJECT_GET_STRUCTURE( alphabetObject, GRAPHIC) ) ;
orxSTRUCTURE *st = orxSTRUCTURE( graphic );
orxTEXT *t2 = orxSTRUCTURE_GET_POINTER(st, TEXT); //returns null
orxTEXT *text = orxTEXT(linkedGraphic ); //also returns null
Comments
When you have your graphic, you should use the orxGraphic API on it to extract its data (which can either be a texture or a text):
Now you might want to get it as a text (if it's a texture, you'll get orxNULL instead):
If you'd rather, you could always call orxStructure_GetID() to see what kind of structure it is beforehand, but the "cast" will do just as well.
Now that you have a text, you need the orxText API to extract its font, if there's one: