Lucian
Member
I added new quest system to my server , and added a new questlistgump for it.
I could open the gump with [QuestList gump but I want this gump opened while clicking quests button in paperdoll is it possible ? How Can I do it?
I used eventsink but not worked , or I used wrong help me .
I used EventSink code like that :
I could open the gump with [QuestList gump but I want this gump opened while clicking quests button in paperdoll is it possible ? How Can I do it?
I used eventsink but not worked , or I used wrong help me .
I used EventSink code like that :
public static void Initialize()
{
EventSink.QuestGumpRequest += new QuestGumpRequestHandler(EventSink_QuestGumpRequest);
CommandSystem.Register("QuestList", AccessLevel.Player, new CommandEventHandler(QuestListCommand));
}
[Usage("QuestList")]
public static void QuestListCommand(CommandEventArgs e)
{
if (e.Mobile is PlayerMobile)
{
e.Mobile.SendGump(new QuestGump(e.Mobile));
}
}
private static void EventSink_QuestGumpRequest( QuestGumpRequestArgs e )
{
foreach ( Gump g in e.Mobile.NetState.Gumps )
{
if ( g is QuestGump )
return;
}
e.Mobile.SendGump( new QuestGump( e.Mobile ) );
}
{
EventSink.QuestGumpRequest += new QuestGumpRequestHandler(EventSink_QuestGumpRequest);
CommandSystem.Register("QuestList", AccessLevel.Player, new CommandEventHandler(QuestListCommand));
}
[Usage("QuestList")]
public static void QuestListCommand(CommandEventArgs e)
{
if (e.Mobile is PlayerMobile)
{
e.Mobile.SendGump(new QuestGump(e.Mobile));
}
}
private static void EventSink_QuestGumpRequest( QuestGumpRequestArgs e )
{
foreach ( Gump g in e.Mobile.NetState.Gumps )
{
if ( g is QuestGump )
return;
}
e.Mobile.SendGump( new QuestGump( e.Mobile ) );
}