Wikia

WoWWiki

API GetZoneText

Talk8
100,559pages on
this wiki
Revision as of 20:28, March 27, 2009 by Markkawika (Talk | contribs)

(diff) ←Older revision | Latest revision (diff) | Newer revision → (diff)
WoW API < GetZoneText

Returns the localized name of the zone the player is in.

zoneName = GetZoneText();

ParametersEdit

ReturnsEdit

zoneName 
String - zone name (localized).

ExampleEdit

local zoneName = GetZoneText();
message(zoneName);

ResultEdit

Message box appears displaying your current zone.

NotesEdit

The event ZONE_CHANGED_NEW_AREA is triggered when the text changes. See also the related functions GetSubZoneText and GetMinimapZoneText.

Additional note: Blizzard also registers the event ZONE_CHANGED_INDOORS. If you know what this event is used for, please edit this page.

The event ZONE_CHANGED_INDOORS would most likely be used if you were creating a minimap modification to notify you that you have gone into a building to change the minimap texture and the text above it to indicate the building you are in -- Salanex

See also the related function GetRealZoneText to find the name of the instance instead of the subzone you happen to be in.

Advertisement | Your ad here

Around Wikia's network

Random Wiki