Iraq-
Sorceror
XmlDoomPoints System
By: SHAMBAMPOW
What is this?
XmlDoomPoints is a system designed to serve as a "light at the end of the tunnel" for players doing the Doom Gauntlet. For players doing Doom, it isn't unlikely to sometimes go days without receiving an artifact, and then suddenly receive 2 or 3 within an hour. This system allows players a more steady and predictable means of obtaining artifacts from Doom Gauntlet.
While the normal random chance remains intact (This can also be removed if you would rather use JUST my system, but I chose to leave it in). Players making rounds in Doom earn points for killing each boss. These points are stored within an XmlAttachment attached to each player.
The Dark Father = 45-55 points. (5x other bosses).
Other Gauntlet Bosses = 9-11 points. (5 other bosses * 10 = ~Dark Father value)
Target Artifact Cost: 500 points. (Takes 5-12 rounds: Easily changed in DoomPointsSettings.cs)
When a player makes enough rounds to earn an artifact, they are rewarded a random one.
The handout for the artifact is the same "For your valor in combating the fallen beast, a special artifact has been bestowed on you." message.
The XmlAttachment stores:
Points: Current # of Points the player has.. Resets back to 0 when artifact is awarded.
TotalPoints: Total # of Points the player has ever had over time.
TotalArtifacts: Total # of Artifacts given to the player using the XmlDoomPoints System.
This system is easy to install, and (since it used XmlAttachments) requires edits only to the OnDeath methods of the Doom Gauntlet Bosses.
Installation:
- Extract XmlDoomPoints.zip into your Customs folder.
- In DemonKnight.cs add
Code:
using Server.Engines.XmlSpawner2;
Code:public static void DistributePoints( BaseCreature creature ) { List<DamageStore> rights = BaseCreature.GetLootingRights( creature.DamageEntries, creature.HitsMax ); for ( int i = rights.Count - 1; i >= 0; --i ) { DamageStore ds = rights[i]; if ( !ds.m_HasRight ) rights.RemoveAt( i ); else { XmlDoomPoints a = (XmlDoomPoints)XmlAttach.FindAttachment( rights[i].m_Mobile, typeof( XmlDoomPoints )); if( a == null ) { XmlAttach.AttachTo( rights[i].m_Mobile, new XmlDoomPoints()); } else { if( creature.GetType() == typeof( DemonKnight ) ) { a.Points += DoomPoints.DarkFatherPoints; a.TotalPoints += DoomPoints.DarkFatherPoints; } else if (creature.GetType() == typeof(AbysmalHorror) || creature.GetType() == typeof(ShadowKnight) || creature.GetType() == typeof(DarknightCreeper) || creature.GetType() == typeof(Impaler) || creature.GetType() == typeof(FleshRenderer) ) { a.Points += DoomPoints.GauntletBossPoints; a.TotalPoints += DoomPoints.GauntletBossPoints; } if( a.Points >= DoomPoints.PointsPerArtifacts ) // if they have reached the points value, give them an artifact. { DistributeArtifact( rights[i].m_Mobile, CreateRandomArtifact() ); a.TotalArtifacts++; a.Points -= DoomPoints.PointsPerArtifacts; } } } } }
- In DemonKnight.cs, AbysmalHorror.cs, DarknightCreeper.cs, Fleshrenderer.cs, Impaler.cs, and ShadowKnight.cs, find the OnDeath method and change it to:
Code:public override void OnDeath( Container c ) { base.OnDeath( c ); if ( !Summoned && !NoKillAwards && DemonKnight.CheckArtifactChance( this ) ) DemonKnight.DistributeArtifact( this ); DemonKnight.DistributePoints( this ); // Added for XmlDoomPoints System by SHAMBAMPOW }
- Restart your server, and it's all set.
* As a staff to check up on a players doom points attachment stats simply type "[GetAtt XmlDoomPoints" and click the player.