PDA

View Full Version : Attuning items


LordAdakos
02-17-2013, 12:13 PM
Is there a way to set attunement status for a weapon?

I know you can take an item, give it to an NPC, and return the base item as a cheap workout for un-attuning items, but what if you want to make the item attuned when you receive it?

Say you were upgrading an attuned dagger through three teirs, and if it was attuned to begin with, you return an attuned version, if it wasn't , you return a tradable version.

Is this possible?

ghanja
02-17-2013, 02:06 PM
Is there a way to set attunement status for a weapon?

I know you can take an item, give it to an NPC, and return the base item as a cheap workout for un-attuning items, but what if you want to make the item attuned when you receive it?

Say you were upgrading an attuned dagger through three teirs, and if it was attuned to begin with, you return an attuned version, if it wasn't , you return a tradable version.

Is this possible?

An "attuned" item is essentially a 'no trade' item. Not sure I'm following your desires. Could you clarify?

LordAdakos
02-17-2013, 03:57 PM
If you are familiar with the Defiant line of weapons, they increase in power progressively though 8 distinct Tiers.
I believe it's crude, simple, rough, etc, - I'm Have a script in place for individuals to upgrade progressively though the tiers, with the reagents becoming more expensive as the quest progresses, but want to avoid twinking if possible.

By that I mean, when the weapon is handed back to the player, they receive a 'clean' version which is not attuned yet. They could theoretically trade this to an alt.
I Could make it no-drop, but I was planning on making an un-attune quest, where it would cost X level and Y AA points to un-attune an item, which would make it quite expensive.

The only way I can think to do it with no-drop is to make a copy of each item that is flagged 'no-drop' or 'droppable' and have the un-attune NPC return the item to the player depending if they want to spend the EXP to turn it into a droppable/tradable item, but was hoping to avoid having to copy/create/flag the 8 Tiers of ~10 weapons each.

Does this help explain it?

c0ncrete
02-17-2013, 04:15 PM
how are you returning the items?

$client->SummonItem() accepts the following parameters

item_id, charges=0, attune=0, aug1=0, aug2=0, aug3=0, aug4=0, aug5=0, slot_id=30

you'll need to check $item#_attuned in your script to get the value of the attuned flag for the item that was turned in

take a look at the return_items subroutine in plugins\check_handin.pl for an example

LordAdakos
02-17-2013, 04:20 PM
I was using

if (plugin::check_handin(\%itemcount, $item_id => 1, $reagent => 1))
{
quest::emote(" blah blah blah");
quest::summonitem($item_id_to_give_to_player);
}



Edit: oooh Thanks! This should work?



if (plugin::check_handin(\%itemcount, $item_id => 1, $reagent => 1))
{
$client->SummonItem($item_id_to_give_to_player,0,1)

}



Thank you, I'll do that right away!