Thread Tools Display Modes
11-20-15, 11:15 PM   #1
sirann
A Flamescale Wyrmkin
Join Date: Mar 2007
Posts: 142
Shift Click Add Keystones to Solve Archaeology Function

Hello,

I recently came across stArchaeology. Thought it was a pretty neat and compact way to view the Archaeology frames. Wanted to rewrite most of it from the ground up (terrible idea I know) to add MoP and WoD artifacts. One thing I did not like, was the fly out solve menu stArch had. Currently, shift left click or shift+ctrl left click will solve the respective race's artifact. However, if I want to socket the artifact to solve, nothing will occur. Manually trying to add keystones to the blizzard_arch_UI button does not work, whether it be clicking the keystone "hole" or dragging the keystone to the socket. No Blizzard Function was prevented by an addon this time.

Please find my code here: http://pastebin.com/dybyj2Zp

All print debugging shows that the proper functions are firing, except, something is blocking the SocketItemToArtifact() function

Last edited by sirann : 11-21-15 at 03:48 PM.
  Reply With Quote
11-21-15, 12:08 AM   #2
semlar
A Pyroguard Emberseer
 
semlar's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2007
Posts: 1,060
You aren't telling it what artifact to solve, presumably "SetSelectedArtifact(i)" should be inside of your "OnMouseDown" function.
  Reply With Quote
11-21-15, 12:18 AM   #3
sirann
A Flamescale Wyrmkin
Join Date: Mar 2007
Posts: 142
Adding the line as suggested causes "Interface action failed because of an AddOn"

An action was blocked because of taint from stArchaeologist - SolveArtifact()
  Reply With Quote
11-21-15, 12:29 AM   #4
semlar
A Pyroguard Emberseer
 
semlar's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2007
Posts: 1,060
Well now you have a new problem, because it appears that you can't call SolveArtifact() directly.

You may be able to create a secure button that /clicks the appropriate "solve" button on the archaeology frame in the interface for you.
  Reply With Quote
11-21-15, 12:34 AM   #5
sirann
A Flamescale Wyrmkin
Join Date: Mar 2007
Posts: 142
oh boy, let me try to contain my excitement

but seriously, thank you!
  Reply With Quote
11-21-15, 03:48 PM   #6
sirann
A Flamescale Wyrmkin
Join Date: Mar 2007
Posts: 142
Original Post updated with new problem.
  Reply With Quote
11-22-15, 01:32 PM   #7
Phanx
Cat.
 
Phanx's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2006
Posts: 5,617
Originally Posted by semlar View Post
Well now you have a new problem, because it appears that you can't call SolveArtifact() directly.
That is incorrect. I call SolveArtifact() directly in Better Archaeology UI (along with socketing keystones) with no secure templates of any kind.

@sirann:
You may want to look at the Better Archaology UI code for an example of how to socket keystones and solve artifacts in one click. I don't have time at the moment to go through your code and compare to figure out what's wrong with it.
__________________
Retired author of too many addons.
Message me if you're interested in taking over one of my addons.
Don’t message me about addon bugs or programming questions.
  Reply With Quote
11-22-15, 03:21 PM   #8
sirann
A Flamescale Wyrmkin
Join Date: Mar 2007
Posts: 142
After a few hours of print debugging, I was able to elucidate the issue. Now I just need to perform archaeology skill checks on login and some other non critical stuff.

When I looked at your code, your "solve button" utilized a blizzard_archaeology template, which I believe is a secure button. Quite literally, if I take out the secure template in my button creation, it'll taint when I try to solve. Setting the secure template back in and reloading fixes the taint.

But all that's fixed!

Thanks for writing your addon so I could learn! And thank you for both of your replies!
  Reply With Quote
11-22-15, 04:33 PM   #9
semlar
A Pyroguard Emberseer
 
semlar's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2007
Posts: 1,060
Originally Posted by Phanx View Post
That is incorrect. I call SolveArtifact() directly in Better Archaeology UI (along with socketing keystones) with no secure templates of any kind.
The error message they posted literally says the call to SolveArtifact was blocked, so if you can call it directly it must have some conditions that aren't being met.

Originally Posted by sirann View Post
When I looked at your code, your "solve button" utilized a blizzard_archaeology template, which I believe is a secure button. Quite literally, if I take out the secure template in my button creation, it'll taint when I try to solve. Setting the secure template back in and reloading fixes the taint.
"ArchaeologyRaceTemplate" is not a secure template, it's a fairly standard button. I don't know what the difference is between that and what you were doing before.

The only thing I can think of is you are somehow attempting to call the function without requiring a hardware event, but the code you've posted thusfar has always included a hardware event.
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » AddOn Help/Support » Right Click Solve Archaeology Function

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