[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions_content.php on line 678: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions_content.php on line 678: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions_content.php on line 678: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions_content.php on line 678: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions_content.php on line 678: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions_content.php on line 678: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions_content.php on line 678: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4668: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4670: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4671: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4672: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
Gryphonheart AddOns - View topic - Associate Item Data in Script?
View unanswered posts | View active topics It is currently Wed Dec 02, 2020 8:49 am



Reply to topic  [ 7 posts ] 
 Associate Item Data in Script? 
Author Message

Joined: Mon Oct 27, 2014 9:25 pm
Posts: 5
Realm Name:
I don't know if this is already a thing, but I was wondering if there was API to Associate Item Data inside script, without having to use the GUI tree? (to help keep my tree clean)

Thanks in advance for any answers.


Mon Sep 05, 2016 9:29 pm
Profile

Joined: Thu Dec 13, 2012 5:01 am
Posts: 90
Realm Name:
I tried to trace this down too just to learn about it, but it's very complicated actually.

All the dynamic actions are stored in a table (GHI_ProvidedDynamicActions), which is loaded by a class instance in "GHI_DynamicActionList()" I think, and then I couldn't figure out how the actions were being called from there.

What exactly are you looking for your item to do?


Mon Sep 12, 2016 6:52 pm
Profile

Joined: Mon Oct 27, 2014 9:25 pm
Posts: 5
Realm Name:
Quite simply, for the sake of keeping stuff in my scripts and trying to not create a very large tree, I want to do the same action as from the Dynamic Actions (Item and Container > Associate Item Data) but instead through my custom Script action if possible.

Much like how there's a GHI_Message("hi") and a (Actions and Effects > Message). I'm wanting to associate multiple items with this one item so I can spawn items from it. Basically a profession system I'm doing in my free time.


Thu Sep 29, 2016 1:13 am
Profile

Joined: Thu Dec 13, 2012 5:01 am
Posts: 90
Realm Name:
I have to confess I'm not sure what associate item data does - I tried it but am not finding any data from the associated item?

anyhow have you looked at this section of the API?

https://github.com/Pilus/Gryphonheart/w ... odify-item


Fri Sep 30, 2016 5:29 am
Profile

Joined: Mon Oct 27, 2014 9:25 pm
Posts: 5
Realm Name:
Yeah, I've looked through the API and from what I can see there is nothing on it.

What it does, from my knowledge, is allows the item to carry the information of another item. If you try to GHI_ProduceItem an item that has not first been accounted for by Associate Item Data, it will not recognize the GUID. It will work for you, the creator, since you have seen the items and don't have to associate the item data, but others will not be able to produce the item because their client has no idea what the item GUID refers to.

Originally I had no idea what associate did, but it's crucial when trying to produce items with an item from what I've encountered. It's fine though, I can keep doing it outside of the scripts for the time being, since it's not that big of a deal.


Wed Oct 05, 2016 2:34 am
Profile

Joined: Thu Dec 13, 2012 5:01 am
Posts: 90
Realm Name:
It actually looks like all the functions are there in the API (.GetGUID, .GetItemInfo etc), but they would only happen upon running the item, unlike Associate Item Data which must execute as soon as you select the item from the editor.

If you're only doing a few, you could just be sure to run them once before trading them to people, but yea, doesn't really save you any hassle.


Thu Oct 06, 2016 3:29 am
Profile

Joined: Thu Dec 13, 2012 5:01 am
Posts: 90
Realm Name:
by the way I have a toon on WrA, Hulain (ally), if you send me a post in game I'd love to catch up with that realm... I know GHI is big there but I'm hardly there anymore.


Thu Oct 06, 2016 3:34 am
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 7 posts ] 

Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group
Designed by ST Software.