Lightfoot8 wrote...
An item can not have a conversation. You will need to have the PC either talk to himself:
AssignCommand(oPC, ActionStartConversation(oPC, "ar_feystone"));
Or create a placeable for the PC to talk to.
BioWare already has a template set up for this.
1) Put the "Cast Spell: Talk to" property on the chosen item
2) Create a conversation with a name matching the item's tag
3) Use the script "x2_iw_cnv_ok" as the starting conditional for initiating the dialog (there is also the script "
x2_iw_cnv_1st
" which can be used as an earlier conditional pertaining to the a conversation branch which will be accessed only the first time through)
4) Use the script
"x2_iw_conv_abort
" for the normal conversation end script and for the abort end script.
5) If you are using the item in a conversation and do not want the default Enserric portrait and name edit the script "x2_s3_intitemtlk" inserting the bolded lines below
//::///////////////////////////////////////////////
//:: Black Blade of Disaster
//:: X2_S0_BlckBlde
//:: Copyright © 2001 Bioware Corp.
//:://////////////////////////////////////////////
/*
Summons a greatsword to battle for the caster
*/
//:://////////////////////////////////////////////
//:: Created By: Andrew Nobbs
//:: Created On: Nov 26, 2002
//:://////////////////////////////////////////////
//:: Last Updated By: Georg Zoeller, July 28 - 2003
#include "x2_inc_intweapon"
//Creates the weapon that the creature will be using.
void spellsCreateItemForSummoned(object oCreator, object oBlade, object oSummon)
{
}
#include "x2_inc_spellhook"
void AssignNameAndPortrait()
{
object oItem = GetNearestObjectByTag("x2_plc_intwp");
SetName(oItem, "NAME_OF_ITEM_GOES_HERE");
SetPortraitId(oItem, PORTRAIT_ID_GOES_HERE);
}
void main()
{
DeleteLocalInt(OBJECT_SELF,"X2_L_IN_INTWEAPON_CONVERSATION");
object oBlade = GetSpellCastItem();
object oCreator = OBJECT_SELF;
IWStartIntelligentWeaponConversation(oCreator,oBlade);
DelayCommand(0.5, AssignNameAndPortrait());
// ActionUnequipItem(oBlade);
}
Modifié par WhiZard, 06 avril 2012 - 03:53 .