|
||
|
|||||||
| Custom Script Release Archive This is a pre-script database archive of what our users had released. |
|
|
Thread Tools | Display Modes |
|
|
#1 (permalink) |
|
Join Date: Aug 2004
Age: 19
Posts: 188
|
I made these scripts cause I hate to do it manually and wanted to post them for yall.
If you are an Owner of a shard, you might like these. I would like to thank harold02 for the hooded robe of umbra. The robe is based off that but I added attributes to it. Ok these items you have 2 choices you can get the robe or the other 3 items. The robe and other 3 do they exact same thing. Updated: Added Only staff can wear these. Idea by arkness_PR |
|
|
|
|
#2 (permalink) | |
|
Join Date: Aug 2004
Age: 19
Posts: 188
|
Quote:
|
|
|
|
|
|
#4 (permalink) |
|
Forum Novice
|
I had added restriction on the past so only staff could wear some items so i just plugged it in into this robe he had i didnt do all the script cuz really i dont have too much time atm but if you want to add it to the others script your welcome to do so...the part to copy and paste its in red and bold you cant miss it. I hope this helps anyone. Enjoy
Code:
using System;
using Server.Items;
namespace Server.Items
{
public class OwnersHoodedRobe : HoodedShroudOfShadows
{
[Constructable]
public OwnersHoodedRobe() : base( 0x2683 )
{
Name = "Owners Hooded Robe ";
Hue = 1175;
LootType = LootType.Blessed;
Attributes.CastRecovery = 100;
Attributes.CastSpeed = 100;
Attributes.LowerManaCost = 100;
Attributes.LowerRegCost = 100;
Attributes.NightSight = 1;
Attributes.RegenHits = 100;
Attributes.RegenMana = 100;
Attributes.RegenStam = 100;
}
public override bool OnEquip( Mobile from )
{
if ( from.AccessLevel != AccessLevel.Player)
{
return true;
}
else
{
from.SendMessage("Only Staff Members May Use This Item");
return false;
}
base.OnEquip( from );
}
public OwnersHoodedRobe( Serial serial ) : base( serial )
{
}
public override void Serialize( GenericWriter writer )
{
base.Serialize( writer );
writer.Write( (int) 0 );
}
public override void Deserialize(GenericReader reader )
{
base.Deserialize( reader );
int version = reader.ReadInt();
}
}
}
|
|
|
|
|
#5 (permalink) | |
|
Join Date: Aug 2004
Age: 19
Posts: 188
|
Quote:
|
|
|
|
|
|
#6 (permalink) |
|
Join Date: Oct 2002
Age: 23
Posts: 4,689
|
Your OnEquip restriction is poor coding. I say that for many reasons, and if you look at BaseSuit (for the GMRobe) you will know why. I suggest that you override the VerifyMove like they did in those scripts. That will prevent a player from moving (and therefore equipping/hiding/trading) the items.
|
|
|
|
|
#7 (permalink) |
|
Join Date: Dec 2003
Location: UK
Age: 24
Posts: 78
|
another thing you could do is make it so it self distructs if a player gets it like on other objects i think this is the code or atleast part of it i still abit noobish. but i hope you get the point i trying to make
public override void OnDoubleClick( Mobile from ) { if ( Parent != from ) if (from.AccessLevel < AccessLevel.Administrator) { from.SendMessage( "When you touch, it vanishes without trace..." ); this.Consume() ; return ; } |
|
|
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|