|
Post by zalamar on Feb 20, 2013 17:09:14 GMT -5
umm this is my script and it uses the base color hues so if it needs changing than it would be helpful and i used armor of fortune to make this script so if that was a bad choice than please help me fix this for future scrips i might make :)
using System; using Server;
namespace Server.Items { Create.new class StuddedChest public class ZusesChest : StuddedChest { public override int LabelNumber{ get{ return 1061098; } } // Zuses Chest public override int ArtifactRarity{ get{ return 12; } }
public override int InitMinHits{ get{ return 255; } } public override int InitMaxHits{ get{ return 255; } }
[Constructable] public ZusesChest() { Hue = 1285; Attributes.HitChance = 15; Attributes.LowerRegCost = 15; ArmorAttributes.MageArmor = 1; Attributes.LowerManaCost = 15 = ; Attributes.Wrestling = 10; }
public ZusesChest( 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(); } }
|
|
|
Post by Jamze on Feb 20, 2013 17:24:07 GMT -5
Looks good. Using the base from something can really be helpful while your still learning. Truthfully, even with a degree in programming and running my own server since 2001, I still have templates I use when making new monsters, weapons or armor. It saves time. Any time you want me to look at something or help, I am more than willing to I am by no means the best at it but I will do everything I can to help. Good job on the script.
|
|
|
Post by Jamze on Feb 20, 2013 17:25:53 GMT -5
One last point, when posting a script on the forums, if you put a (No spaces there at the begining of the script and a ( no spaces) at the end, it makes it all pretty and easier to read.
|
|
|
Post by zalamar on Feb 20, 2013 17:26:13 GMT -5
well somthing is wrong with it and i dont know what maby it is the id or somting but i gotta fit it DX
|
|
|
Post by Jamze on Feb 20, 2013 17:30:00 GMT -5
Hehe Well, saying "Something is wrong with it" doesnt tell me a whole lot. Be more specific with me and ill help. Do you not want the ID of the studded chest?
You can always do a ItemID = (whatever the id is); in the constructable of the item
|
|
|
Post by zalamar on Feb 20, 2013 17:32:12 GMT -5
the ID is of the armor of fortune and the { Create.new class StuddedChest public class ZusesChest : StuddedChest { that is alredy definded
|
|
|
Post by zalamar on Feb 20, 2013 17:37:58 GMT -5
i also changed it to
using System; using Server;
namespace Server.Items { public class ZusesChest : StuddedChest { public override int LabelNumber{ get{ return 1061098; } } // Zuses Chest public override int ArtifactRarity{ get{ return 12; } }
public override int InitMinHits{ get{ return 255; } } public override int InitMaxHits{ get{ return 255; } }
[Constructable] public ZusesChest() { Hue = 2050; Attributes.HitChance = 15; Attributes.LowerRegCost = 15; ArmorAttributes.MageArmor = 1; Attributes.LowerManaCost = 15 = ; Attributes.Wrestling = 10; }
public ZusesChest( 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(); } } }
|
|
|
Post by Jamze on Feb 20, 2013 17:39:51 GMT -5
If you use a label number, you have to have the right cliloc. If its a custom item, just take that part out. The Name = "Zeus' Chest"; Should go in the constructable
|
|
|
Post by zalamar on Feb 20, 2013 17:47:33 GMT -5
thanks that worked a bit more than what i had
|
|
|
Post by zalamar on Feb 20, 2013 17:51:48 GMT -5
i guess i will haft to play with it to get it to work till than i will keep you up to date on changes
|
|
|
Post by zalamar on Feb 20, 2013 17:53:32 GMT -5
now my error is that the namespace "Server.Items" is alreddy defined
|
|
|
Post by zalamar on Feb 20, 2013 17:55:31 GMT -5
this is what i have now
using System; using Server;
namespace Server.Items { public class ZusesChest : StuddedChest { public override int ArtifactRarity{ get{ return 12; } }
public override int InitMinHits{ get{ return 255; } } public override int InitMaxHits{ get{ return 255; } }
[Constructable] public ZusesChest() { The Name = "Zeus' Chest"; Hue = 2050; Attributes.HitChance = 15; ArmorAttributes.MageArmor = 1; Attributes.Wrestling = 10; Attributes.LowerRegCost = Utility.RandomMinMax(5, 20); Attributes.LowerManaCost = Utility.RandomMinMax(5, 20);
}
public ZusesChest( 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(); } } }
|
|
|
Post by zalamar on Feb 20, 2013 18:00:19 GMT -5
would adding using Server.Items; help?
|
|
|
Post by Jamze on Feb 20, 2013 18:09:27 GMT -5
It may. Give me a minute, soon as I can get back on my other computer, ill plug this in and take a closer look at it. Server should be back up in ~5min.
|
|
|
Post by Jamze on Feb 20, 2013 18:40:07 GMT -5
using System; using Server;
namespace Server.Items { public class ZusesChest : StuddedChest { public override int ArtifactRarity { get { return 12; } }
public override int InitMinHits { get { return 255; } } public override int InitMaxHits { get { return 255; } }
[Constructable] public ZusesChest() { Name = "Zeus' Chest"; Hue = 2050; Attributes.AttackChance = 15; ArmorAttributes.MageArmor = 1; //The next line is a skill, not an attribute. //Attributes.Wrestling = 10; SkillBonuses.SetValues(0, SkillName.Wrestling, 10.0); Attributes.LowerRegCost = Utility.RandomMinMax(5, 20); Attributes.LowerManaCost = Utility.RandomMinMax(5, 20);
}
public ZusesChest(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(); } } }
The part that says Name = "Zeus' Chest" Should only be Name Not "The Name" Wrestling is a skill, you have to have that added a different way. There you go
|
|