Go Back   RunUO - Ultima Online Emulation > RunUO > RunUO Post Archive

RunUO Post Archive The Archvie

Reply
 
Thread Tools Display Modes
Old 05-31-2004, 06:00 PM   #1 (permalink)
Forum Expert
 
LordHogFred's Avatar
 
Join Date: Jan 2004
Location: UK, Essex
Age: 19
Posts: 1,166
Default FULL Diablo 2 Style Socket System =)

Just for the record I am no longer supporting this system any more.

Summary:
This is a full Dibalo II style socket system for RunUO v1.0

EDIT: Updated the Loot.cs in the Loot Packs zip file to contain a Loot.cs compatible with RUO 1.0, also removed some custom items in it. I will upgrade the entire system to RunUO 1.0 when I have the time as I have my exams coming up soon and don't have much spare time on my hands, but it will be done

EDIT: Added the missing Loot.cs required to use the LootPack.cs and also updated the 'How To' text file to show how to edit the lootpacks if you have a custom one. Also removed the code sown pasted into BaseCreature.cs because with the Loot Packs it is now useless. Sorry

NEW: Updated system to support the crafting of the socketed items. All socket items require between 95 and 135 skill and all require 5x the amount of resources. I personally think this is a better way than adding the weapons and armour, etc into the LootPack.
Enjoy!

NEW: Lootpacks have finally been added, you can remove the gems from your basecreature.cs now. However I am still working on adding the socketed weapons so leave the weapons, armour and shields in your basecreature.cs for the moment. Download the altered lootpack.cs and just replace your old one, additions are clearly marked if oyu are using your own lootpack.

Enjoy

Is as close to D2 socket system as possible.

Description:
Ok, I have been working non-stop for the past two days on this (I'm pretty new to scripting but I'm quite impressed with myself )

It is a FULL Diablo II style socket system for use with RUO 1.0 it includes:

* Every type of gem: Amethyst, Sapphire, Emerald, Ruby, Topaz, Diamond and Skull.

* Different types of each gem: Chipped, Flawed, Plain, Flawless and Perfect.

* Each gem and skull gives attributes as close to D2 as possible.

* The enhancement results are different depending on whether you have added the gem or skull to a weapon, shield or piece of armor.

* When you enhance an item with a gem or skull it gives the enhanced item a hue close to that gem.

Everything is here, the only thing I haven't added are the different runes yet, I am working on them as I type this

The one thing that I think may need changing slightly is the drop rate of the gems and socketed items and also the chance of getting 1, 2 and 3 sockets on an item. If you change it and find that it works well then please say, also if you want to know how to change those variables say and I will tell you how

Anyway I hope you all enjoy this system,
Happy socketing


PS. I would like to point out that the original Weapon Socket system was NOT mine, however I took it upon myself to expand it and turn it into the full socket system. The amount of work I have put into this system is huge and I take full credit for all my work HOWEVER I also give the original author of the Weapon Socket system credit becuase without him/her I would have had no basis to work from. If you know how they are then please tell me and I will add their name here,

Thanks

EDIT: The original author was Xeus and I thank him making such a system to allow me to make what I have done. Thanks




Installation:
Follow the How To.txt included.

If needed I will upload the altered files.
Attached Files
File Type: zip FULL D2 Socket System - Zip 2.zip (91.5 KB, 2391 views)
File Type: zip FULL D2 Socket System - Zip 1.zip (63.7 KB, 2057 views)
File Type: zip Socket Craft.zip (7.4 KB, 1141 views)
File Type: txt How To.txt (12.6 KB, 1334 views)
File Type: zip Loot Packs.zip (11.0 KB, 537 views)
__________________
It is not the hand that creates worlds,
It is the mind controlling it !

The New Dawn Network

Last edited by LordHogFred; 06-04-2007 at 12:45 AM.
LordHogFred is offline   Reply With Quote
Old 05-31-2004, 06:02 PM   #2 (permalink)
Forum Expert
 
Captain The First's Avatar
 
Join Date: Jun 2003
Location: The Netherlands
Posts: 647
Red face

Hah there it be. I've got an early version of this somewhere that someone had submitted... but this will do me just fine.

Good job next time work faster :P (just kindding of course hehe)
__________________
Captain The First
_________________

Undisclosed shard (status: building since Feb. 2003)
Captain The First is offline   Reply With Quote
Old 05-31-2004, 06:10 PM   #3 (permalink)
Forum Expert
 
LordHogFred's Avatar
 
Join Date: Jan 2004
Location: UK, Essex
Age: 19
Posts: 1,166
Default

hehe

I wasn't aware that a full system had been done before, thats why I did this

Oh well, doesn't look to me like it's on the forums now so here it is
__________________
It is not the hand that creates worlds,
It is the mind controlling it !

The New Dawn Network
LordHogFred is offline   Reply With Quote
Old 05-31-2004, 06:15 PM   #4 (permalink)
Forum Expert
 
Captain The First's Avatar
 
Join Date: Jun 2003
Location: The Netherlands
Posts: 647
Red face

Nono I do believe we probably worked off the same original. Only I never got around to doing all that much with it after I... euh... decided to unfreeze and wipe skara brae just because it was ugly.

Now time to make a test server just for this script :P

Oh Ps unless I missed it you might as well want to add a changed version of the distro files you need to change. It makes it easier for people to throw up a test server and see what your script does.

Saves complaints too if you can say: 'runs as is'
__________________
Captain The First
_________________

Undisclosed shard (status: building since Feb. 2003)
Captain The First is offline   Reply With Quote
Old 05-31-2004, 06:20 PM   #5 (permalink)
 
Join Date: Jan 2004
Posts: 48
Send a message via ICQ to tengeta Send a message via AIM to tengeta
Thumbs up sweet!

wow thats awesome! im gonna add that to my shard asap!
Thanks for making that,
-Tengeta
tengeta is offline   Reply With Quote
Old 05-31-2004, 06:40 PM   #6 (permalink)
Forum Expert
 
Captain The First's Avatar
 
Join Date: Jun 2003
Location: The Netherlands
Posts: 647
Red face

System test completed:

Test statistics:

Server: Runuo 1.0 RC0 server

Installation: Easy


Installation was painless, follow all the instructions they are clear and save a few obvious typos without mistakes.

Tested the system with various weapons and enhancements (not a full system test)

System is 'slightly' powerful for regular OSI shards.

A good addition would be a short description of how to change power and drop rates of the enhancements as well as enhancement fail rate.


Excellent script otherwise.
__________________
Captain The First
_________________

Undisclosed shard (status: building since Feb. 2003)
Captain The First is offline   Reply With Quote
Old 05-31-2004, 06:58 PM   #7 (permalink)
Forum Expert
 
LordHogFred's Avatar
 
Join Date: Jan 2004
Location: UK, Essex
Age: 19
Posts: 1,166
Default

Hey thanks man

Ok I will add how to change power and drop rates

To change power of the enhancements go to the "Socket Gems" folder and then go to the folder of the gem you want to change ie; Amethyst. Then select which type of Amethyst you want to change ie; ChippedAmethyst.

Then in the script you will find lines like these:

Code:
			                  Weapon.UsedSockets += 1;
			                  Weapon.Attributes.WeaponDamage += 8;
						Weapon.Hue = 316;
The line(s) in between the UsedSockets and the Hue are the ones that apply the different attributes.

If you want to change an items enhancement on Armor scroll down till you find:

Code:
			                  Armor.UsedSockets += 1;
			                  Armor.Attributes.BonusStr += 3;
						Armor.Hue = 316;
Again the lines between UsedSockets and Hue are the ones that apply the bonuses.

Shield is the same again except these are the lines needed:

Code:
			                  Shield.UsedSockets += 1;
			                  Shield.Attributes.DefendChance += 8;
						Shield.Hue = 316;

Ok I hope that helps with how to change the bonuses on a gem.


Now to change the drop rates go to BaseCreature.cs and find these lines:

Code:
		private int m_WeaponSocketRoll = Utility.Random( 50 );
		private int m_ArmorSocketRoll = Utility.Random( 50 );
		private int m_ShieldSocketRoll = Utility.Random( 50 );
Just change the 50 to a lower number to increase the drop rate or make it a higher number to decrease the drop rate.

The same goes for the Socket Gems except you use these lines:

Code:
		private int m_ChippedSocketGemRoll = Utility.Random( 20 );
		private int m_FlawedSocketGemRoll = Utility.Random( 40 );
		private int m_PlainSocketGemRoll = Utility.Random( 80 );
		private int m_FlawlessSocketGemRoll = Utility.Random( 150 );
		private int m_PerfectSocketGemRoll = Utility.Random( 200 );
DO NOT touch the other lines near these as it will probably screw everything up

I hope that explains everything, just say if I've missed anythin out
__________________
It is not the hand that creates worlds,
It is the mind controlling it !

The New Dawn Network
LordHogFred is offline   Reply With Quote
Old 05-31-2004, 07:14 PM   #8 (permalink)
Forum Expert
 
Captain The First's Avatar
 
Join Date: Jun 2003
Location: The Netherlands
Posts: 647
Default

Well I guess this is enough reason to make a horardric cube that will transform regular gems into enhancement gems and enhancement gems into better gems.


Anyone else getting the feeling that they're standing in a desert town or that odd desire to go chipped gem hunting?
__________________
Captain The First
_________________

Undisclosed shard (status: building since Feb. 2003)
Captain The First is offline   Reply With Quote
Old 05-31-2004, 07:33 PM   #9 (permalink)
Newbie
 
Join Date: Oct 2002
Location: Brazil
Age: 21
Posts: 74
Send a message via ICQ to Matador Doidao Send a message via MSN to Matador Doidao
Default

really nice system, i really like it

ill keep testing it here
__________________
=)
Matador Doidao is offline   Reply With Quote
Old 05-31-2004, 08:13 PM   #10 (permalink)
Forum Expert
 
LordHogFred's Avatar
 
Join Date: Jan 2004
Location: UK, Essex
Age: 19
Posts: 1,166
Default

Well I have to say I couldn't agree more. I would love to make a Horadric Cube but alas I wou;dn't know where to start. If someone could get the basic code to me (placing X items in a container to form Y item) I would be more than happy to work on one and get it sorrted.
__________________
It is not the hand that creates worlds,
It is the mind controlling it !

The New Dawn Network
LordHogFred is offline   Reply With Quote
Old 05-31-2004, 10:08 PM   #11 (permalink)
*flop*
 
Avangelon's Avatar
 
Join Date: Mar 2004
Location: US, TX
Age: 23
Posts: 56
Send a message via AIM to Avangelon Send a message via MSN to Avangelon Send a message via Yahoo to Avangelon
Exclamation

Xeus is the original author of the socketed weapon script and he is passing on the following to both the author, and the person who wrote this script.

Quote:
Originally said by Xeus
The person who originally wrote this script is me, Xeus. You can find the original script at the following URL:

<URL Deleted due to user being banned REPEATEDLY for spamming this forum with that site>

In the future please request the author's permission before modifying the script and submitting it. You can not possibly say that you do not know who the original author was because there are several documents in the same zip file as the socketed weapon script that contain author contact information.

And to those of you who downloaded his script, and would like to contribute to the original project which is balanced more toward the average UO shard, please visit the URL of the original script and contribute your ideas, weapons, and augmentations.

Thank you all for taking the time to read this, and to check my script out which this script originated from. I looked over this author's script and he did do quite a few modifications to it, and I congratulate him, however he did some things that caused the script to be completely be unbalanced; things such as making weapons have a random amount of sockets. In my script, the amount of sockets is based upon the speed of the weapon.

Xeus
Avangelon is offline   Reply With Quote
Old 06-01-2004, 08:06 AM   #12 (permalink)
 
Join Date: Jul 2003
Location: France
Age: 26
Posts: 34
Default i ve got a probleme

Compiling failed 2 errors

BaseShield.cs line13, colum 3 " Modifiers cannot be placed on property or event accessor declarations"
and
BaseShield.cs line13, colum 11 "a get or set accessor expected"

baseShield.cs


Code:
using System;
using System.Collections;
using Server;
using Server.Network;


namespace Server.Items
{
	public class BaseShield : BaseArmor
	{
		public override ArmorMaterialType MaterialType{ get{ return ArmorMaterialType.Plate; } 
// <Socketed Shield System> diablo 2 system
		private int m_UsedSockets, m_MaxSockets; // line 13
		private string m_SocketLabel, m_AugmentList;
		
		[CommandProperty( AccessLevel.GameMaster )]
		public string AugmentList
		{
			get{ return m_AugmentList; }
			set{ m_AugmentList = value; InvalidateProperties(); }
		}
		
		public virtual string SocketLabel{ get{ return m_SocketLabel; } set{ m_SocketLabel = value; } }
		
		[CommandProperty( AccessLevel.GameMaster )]
		public int UsedSockets
		{
			get{ return m_UsedSockets; }
			set{ m_UsedSockets = value; InvalidateProperties(); }
		}
		
		[CommandProperty( AccessLevel.GameMaster )]
		public int MaxSockets
		{
			get{ return m_MaxSockets; }
			set{ m_MaxSockets = value; InvalidateProperties(); }
		}
// </Socketed Shield System> diablo 2 system


		public BaseShield( int itemID ) : base( itemID )
		{
		}

		public BaseShield( Serial serial ) : base(serial)
		{
		}

		public override void Serialize( GenericWriter writer )
		{
			base.Serialize( writer );

			writer.Write( (int)0 );//version
		}

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();
		}

		public override double ArmorRating
		{
			get
			{
				Mobile m = this.Parent as Mobile;
				double ar = base.ArmorRating;

				if ( m != null )
					return ( ( m.Skills[SkillName.Parry].Value * ar ) / 200.0 ) + 1.0;
				else
					return ar;
			}
		}

		public override int OnHit( BaseWeapon weapon, int damage )
		{
			Mobile owner = this.Parent as Mobile;
			if ( owner == null )
				return damage;
			
			double ar = this.ArmorRating;
			double chance = ( owner.Skills[SkillName.Parry].Value - ( ar * 2.0 ) ) / 100.0;

			if ( chance < 0.01 )
				chance = 0.01;
			/*
			FORMULA: Displayed AR = ((Parrying Skill * Base AR of Shield) รท 200) + 1 

			FORMULA: % Chance of Blocking = parry skill - (shieldAR * 2)

			FORMULA: Melee Damage Absorbed = (AR of Shield) / 2 | Archery Damage Absorbed = AR of Shield 
			*/
			if ( owner.CheckSkill( SkillName.Parry, chance ) )
			{
				if ( weapon.Skill == SkillName.Archery )
					damage -= (int)ar;
				else 
					damage -= (int)(ar / 2.0);

				if ( damage < 0 )
					damage = 0;

				owner.FixedEffect( 0x37B9, 10, 16 );

				if ( Utility.Random( 3 ) == 0 )
					HitPoints -= Utility.Random( 2 );
			}

			return damage;
		}
	}
}
i think that my baseShield.cs is good ...... i must look my basecreature ?
__________________
zed :)
site web: www.membre.lycos.fr/mondevates/
zedar is offline   Reply With Quote
Old 06-01-2004, 08:15 AM   #13 (permalink)
Forum Expert
 
Captain The First's Avatar
 
Join Date: Jun 2003
Location: The Netherlands
Posts: 647
Red face

Quote:
Originally Posted by zedar
Compiling failed 2 errors

BaseShield.cs line13, colum 3 " Modifiers cannot be placed on property or event accessor declarations"
and
BaseShield.cs line13, colum 11 "a get or set accessor expected"

baseShield.cs


Code:
using System;
using System.Collections;
using Server;
using Server.Network;


namespace Server.Items
{
	public class BaseShield : BaseArmor
	{
		public override ArmorMaterialType MaterialType{ get{ return ArmorMaterialType.Plate; } 
// <Socketed Shield System> diablo 2 system
		private int m_UsedSockets, m_MaxSockets; // line 13
		private string m_SocketLabel, m_AugmentList;
		
}

Check the amount of braces you have: public override ArmorMaterialType MaterialType{ get{ return ArmorMaterialType.Plate; }

seems to be missing a brace '}' at the end of that line.

Try adding it and see if it helps, looks like you accidentally deleted the '}'.
__________________
Captain The First
_________________

Undisclosed shard (status: building since Feb. 2003)
Captain The First is offline   Reply With Quote
Old 06-01-2004, 08:22 AM   #14 (permalink)
 
Join Date: Jul 2003
Location: France
Age: 26
Posts: 34
Default

i m too stupid

thank for your help ...
__________________
zed :)
site web: www.membre.lycos.fr/mondevates/
zedar is offline   Reply With Quote
Old 06-02-2004, 12:41 AM   #15 (permalink)
Forum Expert
 
flipside's Avatar
 
Join Date: Nov 2002
Location: the city of angels
Age: 20
Posts: 661
Send a message via ICQ to flipside
Default

I tried modifying the PerfectSkull.cs to enchance both weapons and shields to give spell channeling, fast cast and fast cast recovery, here my the code I used followed by errors,
Code:
		               	  int EnhanceChance = Utility.Random( 1 );
		               	  int DestroyChance = Utility.Random( 500 );
		               	  
		               	  if ( EnhanceChance == 0 ) // Success
				    {
			                  Weapon.UsedSockets += 1;
			                  Weapon.WeaponAttributes.HitLeechHits += 4;
			                  Weapon.WeaponAttributes.SpellChanneling += 1;
					  Weapon.WeaponAttributes.CastSpeed += 1;
					  Weapon.WeaponAttributes.CastRecovery += 1;
						Weapon.Hue = 1109;
			                  
			                  Weapon.AugmentList = Weapon.AugmentList + "\n" + m_Augmentation.Name;
			                  from.PlaySound( 0x2A ); // Anvil
			                  from.SendMessage( "You have successfully enhanced the weapon!" );
			                  m_Augmentation.Delete();
			          }
Quote:
Originally Posted by errors
Scripts: Compiling C# scripts...failed (8 errors, 0 warnings)
- Error: Scripts\Custom\Diablo 2\Sockets\Socket Gems\Amethysts\FlawedAmethyst.c
s: CS1502: (line 80, column 41) The best overloaded method match for 'Server.Uti
lity.Random(int)' has some invalid arguments
- Error: Scripts\Custom\Diablo 2\Sockets\Socket Gems\Amethysts\FlawedAmethyst.c
s: CS1503: (line 80, column 57) Argument '1': cannot convert from 'double' to 'i
nt'
- Error: Scripts\Custom\Diablo 2\Sockets\Socket Gems\Skulls\PerfectSkull.cs: CS
0117: (line 87, column 22) 'Server.AosWeaponAttributes' does not contain a defin
ition for 'SpellChanneling'
- Error: Scripts\Custom\Diablo 2\Sockets\Socket Gems\Skulls\PerfectSkull.cs: CS
0117: (line 88, column 8) 'Server.AosWeaponAttributes' does not contain a defini
tion for 'CastSpeed'
- Error: Scripts\Custom\Diablo 2\Sockets\Socket Gems\Skulls\PerfectSkull.cs: CS
0117: (line 89, column 8) 'Server.AosWeaponAttributes' does not contain a defini
tion for 'CastRecovery'
- Error: Scripts\Custom\Diablo 2\Sockets\Socket Gems\Skulls\PerfectSkull.cs: CS
0246: (line 150, column 22) The type or namespace name 'Weapon' could not be fou
nd (are you missing a using directive or an assembly reference?)
- Error: Scripts\Custom\Diablo 2\Sockets\Socket Gems\Skulls\PerfectSkull.cs: CS
0246: (line 151, column 8) The type or namespace name 'Weapon' could not be foun
d (are you missing a using directive or an assembly reference?)
- Error: Scripts\Custom\Diablo 2\Sockets\Socket Gems\Skulls\PerfectSkull.cs: CS
0246: (line 152, column 8) The type or namespace name 'Weapon' could not be foun
d (are you missing a using directive or an assembly reference?)
Scripts: One or more scripts failed to compile or no script files were found.
- Press return to exit, or R to try again.
It says it doesn't contain a definition for those three things, but if that's the case what would I use to add those features?
flipside is offline   Reply With Quote
Old 06-02-2004, 06:09 AM   #16 (permalink)
Forum Expert
 
Captain The First's Avatar
 
Join Date: Jun 2003
Location: The Netherlands
Posts: 647
Default

*thinks* Not sure and can't test it since I am at work but try using 'AosAttribute.SpellChanneling'
__________________
Captain The First
_________________

Undisclosed shard (status: building since Feb. 2003)
Captain The First is offline   Reply With Quote
Old 06-02-2004, 06:34 AM   #17 (permalink)
Forum Expert
 
LordHogFred's Avatar
 
Join Date: Jan 2004
Location: UK, Essex
Age: 19
Posts: 1,166
Default

Ok first problem I can see is that faster cast and spell channeling, etc are NOT weapon attributes therefore in your code you do not need
Code:
Weapon.WeaponAttribute
It just needs to be
Code:
Weapon.Attribute
Also you must make sure that you have eidted the correct part of the code for the shields and weapons. the start of weapon code begins with
Code:
if ( targeted is BaseWeapon )
and the beginning of the shield code begins with
Code:
if ( targeted is BaseShield )
also in the shield code you need to have
Code:
Shield.Attribute
not
Code:
Weapon.Attribute
I hope that this helps,

PS. Hit Leech Hits is a weaponattribute you don't need to change that
__________________
It is not the hand that creates worlds,
It is the mind controlling it !

The New Dawn Network
LordHogFred is offline   Reply With Quote
Old 06-02-2004, 08:45 PM   #18 (permalink)
Forum Expert
 
flipside's Avatar
 
Join Date: Nov 2002
Location: the city of angels
Age: 20
Posts: 661
Send a message via ICQ to flipside
Default

Some of that stuff had to be changed around a bit but it set me in the right direction, thanks.
flipside is offline   Reply With Quote
Old 06-02-2004, 09:31 PM   #19 (permalink)
 
Join Date: Dec 2003
Posts: 23
Default

how are play suppose to get this stuff
"talking about weapons not gems
Ghetto_Santa is offline   Reply With Quote
Old 06-03-2004, 06:02 AM   #20 (permalink)
Forum Novice
 
Join Date: Dec 2002
Posts: 585
Send a message via ICQ to bleis
Default

I supose this will not work on non AoS ?
__________________
Founder of...
www.Abyss-Centurian.tk
Finaly opened,
www.NordicMyth.dk
bleis is offline   Reply With Quote
Old 06-03-2004, 06:10 AM   #21 (permalink)
Forum Expert
 
LordHogFred's Avatar
 
Join Date: Jan 2004
Location: UK, Essex
Age: 19
Posts: 1,166
Default

Unfortunatly at the moment this won't work with non AoS, however you are more than welcome to edit my scripts to let it support non AoS and I will even look into it for you as well
__________________
It is not the hand that creates worlds,
It is the mind controlling it !

The New Dawn Network
LordHogFred is offline   Reply With Quote
Old 06-03-2004, 06:15 AM   #22 (permalink)
Forum Expert
 
Captain The First's Avatar
 
Join Date: Jun 2003
Location: The Netherlands
Posts: 647
Default

Quote:
how are play suppose to get this stuff
"talking about weapons not gems
The distribution of the socketed weapons and armors is entirely up to you. You could add them to a vendor or the monster loot or make them craftable.

No 'default' distribution method is provided.
__________________
Captain The First
_________________

Undisclosed shard (status: building since Feb. 2003)
Captain The First is offline   Reply With Quote
Old 06-03-2004, 05:54 PM   #23 (permalink)