Mr. Friday
Wanderer
[Hunger command
This command checks your hunger level without having to eat food.
Just type [hunger in game and a description of your hunger level is displayed.
This command checks your hunger level without having to eat food.
Code:
using System;
using System.Collections;
using Server;
using Server.Targeting;
using Server.Mobiles;
namespace Server.Scripts.Commands
{
public class HungerCheck
{
public static void Initialize()
{
Server.Commands.Register( "Hunger", AccessLevel.Player, new CommandEventHandler( GetHunger_OnCommand ) );
}
public static void GetHunger_OnCommand( CommandEventArgs arg )
{
PlayerMobile m = arg.Mobile as PlayerMobile;
if ( m.Hunger < 5 )
m.SendMessage( "You are starving." );
else if ( m.Hunger < 10 )
m.SendMessage( "You are very hungry." );
else if ( m.Hunger < 15 )
m.SendMessage( "You feel quite content." );
else
m.SendMessage( "Your stomach feels bloated and full." );
}
}
}
Just type [hunger in game and a description of your hunger level is displayed.