Thread Tools Display Modes
08/02/14, 03:24 PM   #21
Garkin
 
Garkin's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 832
I child control doesn't have global name, it can't be accessed from outside of the parent control.

Only pins that have defined global name are pins created by CustomCompassPins library - so you can work with pins added by your addons, but not with pins created by game itself.
  Reply With Quote
08/02/14, 03:46 PM   #22
unLeashed3k
AddOn Author - Click to view addons
Join Date: Jul 2014
Posts: 33
I keep getting more and more confused then; so this code does not work? It's been my foundation on attempting to get the pins/markers/anything off the compass.


Lua Code:
  1. for i = 1, ZO_CompassContainer:GetNumChildren() do
  2.    local control = ZO_CompassContainer:GetChild(i)
  3.    if control:GetName() == "whatever" then --I have no idea what is the name of compass pin, so...
  4.    end
  5. end
  Reply With Quote
08/02/14, 04:05 PM   #23
Garkin
 
Garkin's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 832
Originally Posted by unLeashed3k View Post
I keep getting more and more confused then; so this code does not work? It's been my foundation on attempting to get the pins/markers/anything off the compass.
That code works, but just for custom pins from addons. When I posted that code, I didn't know yet, that quest pins are unnnamed.
  Reply With Quote
08/02/14, 04:15 PM   #24
unLeashed3k
AddOn Author - Click to view addons
Join Date: Jul 2014
Posts: 33
Ok, so now I'm going way outside the box but perhaps there's a way to set the Visibility of MAP_PIN_TYPE_QUEST_OFFER to some odd alpha level (0.812) then use GetAlphaCoefficients? Wouldn't tell you the name of the NPC like GetCenterOveredPinInfo would (stringDesciption) but it would at least output something (user defined).

I have no idea what I'm talking about probably! =)
  Reply With Quote
08/02/14, 04:54 PM   #25
Garkin
 
Garkin's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 832
Originally Posted by unLeashed3k View Post
Ok, so now I'm going way outside the box but perhaps there's a way to set the Visibility of MAP_PIN_TYPE_QUEST_OFFER to some odd alpha level (0.812) then use GetAlphaCoefficients? Wouldn't tell you the name of the NPC like GetCenterOveredPinInfo would (stringDesciption) but it would at least output something (user defined).

I have no idea what I'm talking about probably! =)
This won't help. ZO_CompassContainer:GetAlphaCoefficients(pinType) method can tell you what is alpha coefficient for given pinType, but nothing else.

But as pins are created on compass, there should be way to get information about those pins at the time when they are created. I'd try to check if there is some event which can be used. I'm not in game right now, so I can't test it, but my guess is this event:

EVENT_PLAYER_IN_PIN_AREA_CHANGED (*integer* _pinType_, *integer* _param1_, *integer* _param2_, *integer* _param3_, *bool* _playerIsInside_)
  Reply With Quote
08/02/14, 04:59 PM   #26
unLeashed3k
AddOn Author - Click to view addons
Join Date: Jul 2014
Posts: 33
Originally Posted by Garkin View Post
This won't help. ZO_CompassContainer:GetAlphaCoefficients(pinType) method can tell you what is alpha coefficient for given pinType, but nothing else.

But as pins are created on compass, there should be way to get information about those pins at the time when they are created. I'd try to check if there is some event which can be used. I'm not in game right now, so I can't test it, but my guess is this event:

EVENT_PLAYER_IN_PIN_AREA_CHANGED (*integer* _pinType_, *integer* _param1_, *integer* _param2_, *integer* _param3_, *bool* _playerIsInside_)
I played around with that for a few hours with no results (that I was looking for). It seems to fire when your compass turns blue because you entered a quest_objective area.

Edit: Unfortunately all my attempts would fail even if I could do what I wanted to, because COMPASS.container (ZO_Compasscontainer) keeps getting more elements as I move around (new markers are added) in the world but elements that are no longer visible on the compass remain. So, while I could collect information and assign it an ID within my own table I'll never be able to remove an element (again from my own table) because COMPASS.container never forgets an element it has seen.

Terribly sorry if I'm explaining this wrong but a simple example is when I enter the world and run a script to GetNumChildren() from COMPASS.container it will show I have 67 children attached to that control (apparently I call them "elements" above ha!) and then move a few meters until a Quest Offer NPC shows on the COMPASS.container (doesn't matter where; can be on the left, right, or anywhere in between) the function call GetNumChildren() will now output 68. Victory! It does exist somewhere! ...but if I move back exactly (180 degree) the way I came until the markers fades (not visible anymore on the compass) GetNumChildren will still output 68.

So as I was saying, if GetNumChildren() never decreases while moving through the world then, even if I could get the information I wanted, I would still need to know it no longer is available information. Thus the title of my thread "Compass Events" =)

Last edited by unLeashed3k : 08/02/14 at 05:20 PM.
  Reply With Quote
08/05/14, 02:38 PM   #27
unLeashed3k
AddOn Author - Click to view addons
Join Date: Jul 2014
Posts: 33
While I can't find anything new (or changed) that would help me produce the results I would desire are there any new functions, events, *anything* dealing with the Compass?

Tried to find GetAllVisibleCompassMarkersNoMatterWhichWayYouAreFacing() as a new function but no deal! ~laughs~

But seriously, though, anyone come across anything new?

Edit: I do believe I'm at the point I am willing to pay(pal) someone for a solution. ~laughs~ ...no, really. I am.

Last edited by unLeashed3k : 08/05/14 at 03:37 PM.
  Reply With Quote

ESOUI » Developer Discussions » Lua/XML Help » Compass Events

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off