Morgion

Member
Morgion submitted a new resource:

Health Orb - Diablo III style healing

This simple script will add Diablo 3 style health orbs.
When player moves over them, it will heal all players and controlled pets within 4 tiles radius, for 20 (+enhance bonus potions) percent of their maximum hit points or remove poison when target is poisoned.

Installation:
Just drop it somewhere to Scripts folder.
To trigger it, add line
HealthOrb.Drop(harmedMobileHere);
in PlayerMobile or BaseCreature or specific monster script to OnDamage(...), OnBeforeDeath() etc.

Read more about this resource...
 
This is an example of how to add it to a specific mob script, for example Rat.cs
C#:
Expand Collapse Copy
public override void OnDamage(int amount, Mobile from, bool willKill)
{
    base.OnDamage(amount, from, willKill);

    if (Utility.RandomDouble() > .25)
        HealthOrb.Drop(this);
}
 
C#:
Expand Collapse Copy
C:\ServUO\Scripts\Custom\Custom Items\HealthOrb.cs(15,30): error CS0246: The type or namespace name 'SelfDeletingItem' could not be found (are you missing a using directive or an assembly reference?) [C:\ServUO\Scripts\Scripts.csproj]
C:\ServUO\Scripts\Custom\Custom Items\HealthOrb.cs(56,30): error CS0115: 'HealthOrb.HandlesOnMovement': no suitable method found to override [C:\ServUO\Scripts\Scripts.csproj]
C:\ServUO\Scripts\Custom\Custom Items\HealthOrb.cs(58,30): error CS0115: 'HealthOrb.OnMovement(Mobile, Point3D)': no suitable method found to override [C:\ServUO\Scripts\Scripts.csproj]
C:\ServUO\Scripts\Custom\Custom Items\HealthOrb.cs(66,30): error CS0115: 'HealthOrb.OnDoubleClick(Mobile)': no suitable method found to override [C:\ServUO\Scripts\Scripts.csproj]
C:\ServUO\Scripts\Custom\Custom Items\HealthOrb.cs(127,30): error CS0115: 'HealthOrb.OnDelete()': no suitable method found to override [C:\ServUO\Scripts\Scripts.csproj]
C:\ServUO\Scripts\Custom\Custom Items\HealthOrb.cs(138,30): error CS0115: 'HealthOrb.Serialize(GenericWriter)': no suitable method found to override [C:\ServUO\Scripts\Scripts.csproj]
C:\ServUO\Scripts\Custom\Custom Items\HealthOrb.cs(144,30): error CS0115: 'HealthOrb.Deserialize(GenericReader)': no suitable method found to override [C:\ServUO\Scripts\Scripts.csproj]
 

Donations

Total amount
$150.00
Goal
$500.00

Shards

Back