I'm trying to make a basic fedex quest, but i cant figure out how to make it so some conversation options only come up when the PC has a certain item
Thanks
~Evangel
Scripting help
Moderator: Event DM
-
- Scholar of Fools
- Posts: 313
- Joined: Mon May 24, 2004 10:50 am
- Location: Australia, Brisbane (GMT +10)
Scripting help
<Fuzz> thankfully, no one quotes me
<GairusWHO> I think so... but don't quote me on that.
<NWDuneAuron> in other news, study proves studies don't prove anything!
- Final Shinryuu
- Sage
- Posts: 2060
- Joined: Thu Jun 24, 2004 3:20 am
- Location: http://hades.mercuric.net/
Re: Scripting help
In the conversation editor, there's an option on the bottom-right side where you can put in a script to govern when the selected conversation option appears.Anniko wrote:I'm trying to make a basic fedex quest, but i cant figure out how to make it so some conversation options only come up when the PC has a certain item
Thanks
~Evangel
There's also a button for the Script Wizard there. Click that, let it do the work for you.

- Aloro
- Team Member; Retired with Honors
- Posts: 12805
- Joined: Sat Dec 28, 2002 5:11 am
- Location: Rainbow's End
- Contact:
In short, you're looking for a conditional script.
Here's a sample script that checks to see if the PC has 100 gold:
This would go in the "Text Appears When" area for the conversation line in question. Replace the script with your own StartingConditional, and it should work fine.
- Aloro
Here's a sample script that checks to see if the PC has 100 gold:
Code: Select all
int StartingConditional()
{
int iResult;
object oPC = GetPCSpeaker();
if (GetGold(oPC) >= 100)
return TRUE;
return FALSE;
}
- Aloro
Aleksandr Solzhenitsyn wrote:The meaning of earthly existence lies, not as we have grown used to thinking, in prosperity, but in the development of the soul.