View Single Post
03-13-18, 12:18 PM   #4
Ammako
A Frostmaul Preserver
AddOn Author - Click to view addons
Join Date: Jun 2016
Posts: 256
Also, as far as I'm aware, there isn't an easy/straightforward way to tell whether you are in an inn or not, unless you want the shop music to constantly play while you are anywhere in a major city.

You get a ZONE_CHANGED event firing whenever you enter a new area, at which point you can check sub-zone text, but many inns don't have a separate sub-zone text in cities, so you can't differentiate inns from other parts of the city that way.

I guess you'd have to get exact coordinate mappings for all inns within cities, and play the inn music only while you are inside those coordinates. For non-city inns, IsResting would probably be accurate enough.
  Reply With Quote