Ejemplo n.º 1
0
 public static void InvokeRacialAbilityRequest(RacialAbilityRequestEventArgs e)
 {
     if (RacialAbilityRequest != null)
     {
         RacialAbilityRequest(e);
     }
 }
Ejemplo n.º 2
0
        private static void EventSink_RacialAbilityUsed( RacialAbilityRequestEventArgs e )
        {
            PlayerMobile from = e.Mobile as PlayerMobile;

            if ( from == null )
                return;

            switch ( e.AbilityID )
            {
                case 1:
                    {
                        /*
                         * TODO (SA): ¿Dónde van estos CliLocs?
                         * - You must heal before flying.	1112454
                         * - You can't use this while flying!	1113414
                         * - You may not continue while flying.	1113589
                         */

                        if ( from.Race == Race.Gargoyle )
                        {
                            if ( !from.Flying )
                            {
                                if ( from.Spell == null )
                                {
                                    Spell spell = new FlySpell( from );

                                    spell.Cast();
                                }
                            }
                            else if ( IsValidLandLocation( from.Location, from.Map ) )
                            {
                                from.Animate( 0xA );
                                from.Flying = false;
                            }
                            else
                                from.LocalOverheadMessage( MessageType.Regular, 0x3B2, 1113081 ); // You may not land here.
                        }

                        break;
                    }
            }
        }
Ejemplo n.º 3
0
 public void InvokeRacialAbilityRequest( RacialAbilityRequestEventArgs e )
 {
     if ( RacialAbilityRequest != null )
         RacialAbilityRequest( e );
 }