mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-04-22 20:57:46 +00:00

Fixed the Coming to Ul'dah and Coming to Limsa Quests, also Fixed the Openings having Black Bards and not being able to jump
202 lines
4.9 KiB
ChaiScript
202 lines
4.9 KiB
ChaiScript
// This is an automatically generated chai script template
|
|
// Content needs to be added by hand to make it function
|
|
// In order for this script to be loaded, change its extension to .chai
|
|
// and move it to the correct folder in bin/scripts/chai/quest
|
|
|
|
// Quest Script: ManSea001_00107
|
|
// Quest Name: Coming to Limsa Lominsa
|
|
// Quest ID: 65643
|
|
// Start NPC: 1001028
|
|
// End NPC: 1002697
|
|
|
|
class ManSea001Def
|
|
{
|
|
def ManSea001Def()
|
|
{
|
|
// Basic quest information
|
|
this.name = "Coming to Limsa Lominsa";
|
|
this.id = 65643;
|
|
|
|
// Quest vars / flags used
|
|
// GetQuestBitFlag8
|
|
// GetQuestUI8AL
|
|
|
|
// Steps in this quest ( 0 is before accepting,
|
|
// 1 is first, 255 means ready for turning it in
|
|
this.SEQ_0 = 0;
|
|
this.SEQ_1 = 1;
|
|
this.SEQ_FINISH = 255;
|
|
|
|
// Quest rewards
|
|
this.RewardExpFactor = 50;
|
|
this.RewardGil = 103;
|
|
|
|
// Entities found in the script data of the quest
|
|
this.ACTOR0 = 1001028;
|
|
this.ACTOR1 = 1002732;
|
|
this.ACTOR2 = 1002697;
|
|
this.CUT_EVENT = 202;
|
|
this.EOBJECT0 = 2001679;
|
|
this.EOBJECT1 = 2001680;
|
|
this.EVENT_ACTION_SEARCH = 1;
|
|
this.LOC_ACTOR0 = 1002732;
|
|
this.LOC_POS_ACTOR0 = 4107186;
|
|
this.OPENING_EVENT_HANDLER = 1245185;
|
|
this.POPRANGE0 = 4127803;
|
|
this.TERRITORYTYPE0 = 181;
|
|
|
|
}
|
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
// Available Scenes in this quest, not necessarly all are used
|
|
def Scene00000( player )
|
|
{
|
|
player.eventPlay( this.id, 0, 0x2000, 0, 0,
|
|
fun( player, eventId, param1, param2, param3 )
|
|
{
|
|
if( param2 == 1 )
|
|
{
|
|
player.setOpeningSequence( 2 );
|
|
ManSea001.Scene00001( player );
|
|
}
|
|
});
|
|
}
|
|
|
|
def Scene00001( player )
|
|
{
|
|
player.eventPlay( this.id, 1, 0xF8482EFB, 0, 0,
|
|
fun( player, eventId, param1, param2, param3 )
|
|
{
|
|
ManSea001.Scene00002( player );
|
|
});
|
|
}
|
|
|
|
def Scene00002( player )
|
|
{
|
|
player.eventPlay( this.id, 2, HIDE_HOTBAR, 0/*unk*/, 0/*unk*/,
|
|
fun( player, eventId, param1, param2, param3 )
|
|
{
|
|
ManSea001.Scene00003( player );
|
|
});
|
|
}
|
|
|
|
def Scene00003( player )
|
|
{
|
|
player.eventPlay( this.id, 3, NONE, 0, 0,
|
|
fun( player, eventId, param1, param2, param3 )
|
|
{
|
|
player.questUpdate( ManSea001.id, 0x01 ); // add quest to player.
|
|
|
|
// update the instance boundaries, call to the opening event
|
|
player.eventPlay( ManSea001.OPENING_EVENT_HANDLER, 0x1E, 0x2001, 1, 0);
|
|
});
|
|
}
|
|
|
|
def Scene00004( player )
|
|
{
|
|
player.eventPlay( this.id, 4, NONE, 0, 0 );
|
|
}
|
|
|
|
def Scene00005( player )
|
|
{
|
|
player.eventPlay( this.id, 5, HIDE_HOTBAR, 0/*unk*/, 0/*unk*/,
|
|
fun( player, eventId, param1, param2, param3 )
|
|
{
|
|
ManSea001.Scene00006( player );
|
|
});
|
|
}
|
|
|
|
def Scene00006( player )
|
|
{
|
|
player.eventPlay( this.id, 6, 0x20, 0/*unk*/, 0/*unk*/,
|
|
fun( player, eventId, param1, param2, param3 )
|
|
{
|
|
if( param2 == 1 )
|
|
{
|
|
player.questUpdate( ManSea001.id, ManSea001.SEQ_FINISH );
|
|
player.prepareZoning( player.getZoneId(), true, 1, 0 );
|
|
player.changePos( 9, 40, 14, 2 );
|
|
}
|
|
});
|
|
}
|
|
|
|
def Scene00007( player )
|
|
{
|
|
player.eventPlay( this.id, 7, NONE, 0, 0 );
|
|
}
|
|
|
|
def Scene00008( player )
|
|
{
|
|
player.eventPlay( this.id, 8, NONE, 0, 0 );
|
|
}
|
|
|
|
def Scene00009( player )
|
|
{
|
|
player.eventPlay( this.id, 9, NONE, 0, 0 );
|
|
}
|
|
|
|
def Scene00010( player )
|
|
{
|
|
player.eventPlay( this.id, 10, NONE, 0, 0 );
|
|
}
|
|
|
|
def Scene00011( player )
|
|
{
|
|
player.eventPlay( this.id, 11, 0x2c02, 0, 0,
|
|
fun( player, eventId, param1, param2, param3 )
|
|
{
|
|
ManSea001.Scene00012( player );
|
|
});
|
|
}
|
|
|
|
def Scene00012( player )
|
|
{
|
|
player.eventPlay( this.id, 12, 0x20, 0, 0,
|
|
fun( player, eventId, param1, param2, param3 )
|
|
{
|
|
if( param2 == 1 )
|
|
{
|
|
if( player.giveQuestRewards( ManSea001.id, 0 ) )
|
|
{
|
|
player.questFinish( ManSea001.id );
|
|
}
|
|
}
|
|
});
|
|
}
|
|
|
|
def Scene00013( player )
|
|
{
|
|
player.eventPlay( this.id, 13, NONE, 0, 0 );
|
|
}
|
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
def onTalk( eventId, player, actorId )
|
|
{
|
|
var actor = mapActor( actorId );
|
|
switch( actor )
|
|
{
|
|
case( this.ACTOR0 )
|
|
{
|
|
this.Scene00000( player );
|
|
break;
|
|
}
|
|
case( this.ACTOR1 )
|
|
{
|
|
this.Scene00005( player );
|
|
break;
|
|
}
|
|
case( this.ACTOR2 )
|
|
{
|
|
this.Scene00011( player );
|
|
break;
|
|
}
|
|
default
|
|
{
|
|
|
|
}
|
|
}
|
|
}
|
|
|
|
};
|
|
|
|
GLOBAL ManSea001 = ManSea001Def();
|