自己蘇生
- カテゴリー: スクリプト
- 重要性: 普通
- 投稿日: 2006-08-18 (金) 19:03:51
単独または少人数サーバで蘇生が面倒なときに便利です。
Scripts\Engines\Virtues\Sacrifice.csの public static void Resurrect( Mobile from )にある
if ( from.Criminal )
{
from.SendLocalizedMessage( 1052007 ); // You cannot use this ability while flagged as a criminal.
}
else if ( !VirtueHelper.IsSeeker( from, VirtueName.Sacrifice ) )
{
from.SendLocalizedMessage( 1052004 ); // You cannot use this ability.
}
else if ( pm.AvailableResurrects <= 0 )
{
from.SendLocalizedMessage( 1052005 ); // You do not have any resurrections left.
}
else
{
// We need to wait for them to accept the gump or they can just use
// Sacrifice and cancel to have items in their backpack for free.
from.CloseGump( typeof( ResurrectGump ) );
from.SendGump( new ResurrectGump( from, true ) );
}
以上のコードを、以下の2行だけにします。
from.CloseGump( typeof( ResurrectGump ) );
from.SendGump( new ResurrectGump( from, true ) );
これで徳メニューの献身で自己蘇生ができます。