2017-08-08 13:53:47 +02:00
|
|
|
// Opening Script: OpeningGridania
|
|
|
|
// Quest Name: OpeningGridania
|
|
|
|
// Quest ID: 1245186
|
|
|
|
|
|
|
|
class OpeningGridaniaDef
|
|
|
|
{
|
|
|
|
|
|
|
|
def OpeningGridaniaDef()
|
|
|
|
{
|
|
|
|
this.id = 1245186;
|
|
|
|
this.name = "OpeningGridania";
|
|
|
|
|
|
|
|
this.ERANGE_HOWTO_ANN_AND_QUEST = 2117539;
|
|
|
|
this.ERANGE_HOWTO_QUEST_REWARD = 2366417;
|
|
|
|
this.ERANGE_SEQ_1_CLOSED_1 = 2351918;
|
|
|
|
this.POS_SEQ_1_CLOSED_RETURN_1 = 2351921;
|
|
|
|
this.ERANGE_SEQ_1_CLOSED_2 = 2351919;
|
|
|
|
this.POS_SEQ_1_CLOSED_RETURN_2 = 2351921;
|
|
|
|
this.ERANGE_ALWAYS_CLOSED_1 = 2280846;
|
|
|
|
this.POS_ALWAYS_CLOSED_RETURN_1 = 2320804;
|
|
|
|
this.ENPC_ALWAYS_CLOSED_1 = 2367988;
|
|
|
|
this.ERANGE_ALWAYS_CLOSED_3 = 2280851;
|
|
|
|
this.POS_ALWAYS_CLOSED_RETURN_3 = 2320811;
|
|
|
|
this.ENPC_ALWAYS_CLOSED_3 = 2563491;
|
|
|
|
this.BGM_MUSIC_ZONE_FST_TWN = 1003;
|
|
|
|
this.NCUT_FST_1 = 3;
|
|
|
|
this.NCUT_FST_2 = 53;
|
|
|
|
this.NCUT_FST_3 = 226;
|
|
|
|
this.ENPC_QUEST_OFFER = 1985150;
|
|
|
|
this.NCUT_LIGHT_ALL = 2;
|
|
|
|
this.NCUT_LIGHT_FST_1 = 147;
|
|
|
|
this.NCUT_LIGHT_FST_2 = 146;
|
|
|
|
}
|
|
|
|
|
|
|
|
def Scene00000( player )
|
|
|
|
{
|
2017-10-01 04:14:54 +10:00
|
|
|
player.eventPlay( this.id, 0, 0x04AC05, 0, 1,
|
2017-08-08 13:53:47 +02:00
|
|
|
fun( player, eventId, param1, param2, param3 )
|
|
|
|
{
|
2017-08-20 02:24:19 +02:00
|
|
|
player.setOpeningSequence( 1 );
|
2017-08-08 13:53:47 +02:00
|
|
|
OpeningGridania.Scene00001( player );
|
|
|
|
} );
|
|
|
|
}
|
|
|
|
|
|
|
|
def Scene00001( player )
|
|
|
|
{
|
|
|
|
player.eventPlay( this.id, 1, 0x2001, 1, 0x32 );
|
|
|
|
}
|
|
|
|
|
|
|
|
def Scene00020( player )
|
|
|
|
{
|
|
|
|
player.eventPlay( this.id, 20, 0x2001, 0, 1 );
|
|
|
|
}
|
|
|
|
|
|
|
|
def Scene00030( player )
|
|
|
|
{
|
|
|
|
player.eventPlay( this.id, 30, 0x2001, 0, 0 );
|
|
|
|
}
|
|
|
|
|
|
|
|
def Scene00040( player )
|
|
|
|
{
|
|
|
|
player.eventPlay( this.id, 40, 1, 2, 1,
|
|
|
|
fun( player, eventId, param1, param2, param3 )
|
|
|
|
{
|
2017-08-20 02:24:19 +02:00
|
|
|
if( player.getOpeningSequence() == 2 )
|
2017-08-08 13:53:47 +02:00
|
|
|
{
|
|
|
|
// update the instance boundaries
|
|
|
|
OpeningGridania.Scene00030( player );
|
|
|
|
}
|
|
|
|
} );
|
|
|
|
}
|
|
|
|
|
|
|
|
////////////////////////////// EVENT HANDLERS //////////////////////////////////
|
|
|
|
|
|
|
|
def onEnterTerritory( eventId, player, param1, param2)
|
|
|
|
{
|
2017-08-20 02:24:19 +02:00
|
|
|
if( player.getOpeningSequence() == 0 )
|
2017-08-08 13:53:47 +02:00
|
|
|
{
|
|
|
|
this.Scene00000( player );
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
this.Scene00040( player );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
def onWithinRange( eventId, player, param1, x, y, z)
|
|
|
|
{
|
|
|
|
if( this.ERANGE_ALWAYS_CLOSED_3 == param1 )
|
|
|
|
{
|
|
|
|
this.Scene00020( player );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
GLOBAL OpeningGridania = OpeningGridaniaDef();
|