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

RunUO Post Archive The Archvie

Reply
 
Thread Tools Display Modes
Old 05-30-2004, 03:46 PM   #1 (permalink)
Forum Expert
 
Join Date: Dec 2003
Age: 35
Posts: 462
Send a message via ICQ to dstarz20 Send a message via AIM to dstarz20
Default Thieves Cloak

Summary:
Expounded on Tru's Hooded Robe. Thanks to tru, he did most of the work, I just twisted a few things.

Description:
When Hood is up, it adds 20 to your stealing.

Just add to Custom folder. [add Thievescloak

Thanks!

Installation:
Add to custom folder
Attached Files
File Type: cs ThievesCloak.cs (2.9 KB, 401 views)
dstarz20 is offline   Reply With Quote
Old 05-30-2004, 10:49 PM   #2 (permalink)
 
Join Date: Nov 2003
Posts: 111
Default hooded robe thieves cloak

Ive seen the same code reposted in dozens of items and all have the same problem which no 1 can seem 2 fix, when the player has a lord or lady title if they use the robe it says Lord A Shrouded figure or Lady A Shrouded figure..I wonder why any1 hasnt picked that up yet or fixed the problem!
__________________


You want some? Come get some!
SonnyJim is offline   Reply With Quote
Old 05-30-2004, 11:30 PM   #3 (permalink)
Tru
Forum Expert
 
Tru's Avatar
 
Join Date: Jan 2003
Location: California
Age: 39
Posts: 3,260
Default

Quote:
Originally Posted by SonnyJim
Ive seen the same code reposted in dozens of items and all have the same problem which no 1 can seem 2 fix, when the player has a lord or lady title if they use the robe it says Lord A Shrouded figure or Lady A Shrouded figure..I wonder why any1 hasnt picked that up yet or fixed the problem!
Only way to change it is to reset thier fame/karma..
Tru is offline   Reply With Quote
Old 05-30-2004, 11:32 PM   #4 (permalink)
 
Join Date: Apr 2004
Location: Michigan
Age: 19
Posts: 11
Send a message via Yahoo to BattleCry
Default

Well think about it.. When the hood is over your head.. Your face isnt shown, hiding you.. It helps you if you're a thief and dont want you name flashed around.. And when you double click the robe the hood goes down.. And that reveals your identity..
BattleCry is offline   Reply With Quote
Old 05-31-2004, 12:23 AM   #5 (permalink)
Let's have some pancakes.
 
Dooder's Avatar
 
Join Date: Jul 2003
Location: St. Louis, MO
Posts: 85
Send a message via ICQ to Dooder Send a message via AIM to Dooder
Default

Quote:
Originally Posted by Tru
Only way to change it is to reset thier fame/karma..
Im not very good at C# yet, but couldn't you use an OnEquip to set their fame/karma to 0, and then OnRemoval(I think...) to set it back to what it had been before? I dont know if that is possible or not...Just a thought..
Dooder is offline   Reply With Quote
Old 05-31-2004, 10:56 AM   #6 (permalink)
Forum Expert
 
Join Date: Dec 2003
Age: 35
Posts: 462
Send a message via ICQ to dstarz20 Send a message via AIM to dstarz20
Default

Are you saying that I re-posted something that has already been used / thought of before? I have never seen it, sorry. If so, feel free to remove. Or, are you just remarking on the Title issue? Thanks. :}
dstarz20 is offline   Reply With Quote
Old 05-31-2004, 01:44 PM   #7 (permalink)
Tru
Forum Expert
 
Tru's Avatar
 
Join Date: Jan 2003
Location: California
Age: 39
Posts: 3,260
Default

Quote:
Originally Posted by Dooder
Im not very good at C# yet, but couldn't you use an OnEquip to set their fame/karma to 0, and then OnRemoval(I think...) to set it back to what it had been before? I dont know if that is possible or not...Just a thought..
You would have to store the original fame/karma so that it could be referenced on removal
Tru is offline   Reply With Quote
Old 06-01-2004, 02:58 AM   #8 (permalink)
 
Join Date: Nov 2003
Posts: 111
Default hooded robe

Quote:
Originally Posted by Tru
You would have to store the original fame/karma so that it could be referenced on removal

Tru ur the creator of this script that every1 modifes isnt there any way u cant fix the fame issue? cos i finks its an excellent script but the fame issues stuffs it up a bit
__________________


You want some? Come get some!
SonnyJim is offline   Reply With Quote
Old 06-02-2004, 07:42 AM   #9 (permalink)
Zigler
Guest
 
Posts: n/a
Default

you dont set the fame to 0.. what you can do those is script it to take away say -100000 fame.. and add it back when you put the hood down.. thus it wont have to save the info.. shouldnt be hard for you to do.. if you have problems... ill do it for you.

***********************

Dled the script to look and see what i could do with it.. and heres a fix
anyone with over 10000 fame will be set to -100000 when they put the hood up..
anyone with -100000 fame will be set to 12000 when they put the hood down.. now I know this isnt exact and but it will work and give them a little buffer to die and keep there title.. anyone that doesnt have 10000+ karma or -100000 karma does not get altered.. heres the modified script...

Code:
using System; 
using Server.Items; 

namespace Server.Items 
{ 
   public class ThievesCloak : BaseArmor 
   {

		public override int InitMinHits{ get{ return 255; } }
		public override int InitMaxHits{ get{ return 255; } } 

      public override ArmorMaterialType MaterialType{ get{ return ArmorMaterialType.Plate; } } 

                public override int ArtifactRarity{ get{ return 99; } } 

      [Constructable] 
      public ThievesCloak() : base( 0x2683 )
      {
         Weight = 5.0;
         Name = "Shroud";
      }

      public override void OnDoubleClick( Mobile m )
      {
         if( Parent != m )
         {
            m.SendMessage( "You must be wearing the robe to use it!" );
         }
         else
         {
            if ( ItemID == 0x2683 || ItemID == 0x2684 )
            {
               m.SendMessage( "You lower the hood." );
               m.PlaySound( 0x57 );
               ItemID = 0x1F03;
               m.NameMod = null;
               m.RemoveItem(this);
               m.EquipItem(this);
               if( m.Kills >= 5)
               {
               m.Criminal = true;
                }
                if( m.GuildTitle != null)
               {
                  m.DisplayGuildTitle = true;
                }
            }
            else if ( ItemID == 0x1F03 || ItemID == 0x1F04 )
            {
               m.SendMessage( "You pull the hood over your head." );
               m.PlaySound( 0x57 );
               ItemID = 0x2683;
               m.NameMod = "a shrouded figure";
               m.DisplayGuildTitle = false;
               m.Criminal = false;
               m.RemoveItem(this);
               m.EquipItem(this);
	    SkillBonuses.SetValues( 0, SkillName.Stealing, 20.0 );

	    if ( m.Fame >= 10000 )
         	     m.Fame = -50000;

            }
         }
      }

       public override bool OnEquip( Mobile from )
      {
         if ( ItemID == 0x2683 )
         {
         from.NameMod = "a shrouded figure";
         from.DisplayGuildTitle = false;
         from.Criminal = false;
         }
         return base.OnEquip(from);
      }

      public override void OnRemoved( Object o )
      {
      if( o is Mobile )
      {
          ((Mobile)o).NameMod = null;
      }
      if( o is Mobile && ((Mobile)o).Fame <= -20000 )
	    {
          ((Mobile)o).Fame = 12000;
               }
      if( o is Mobile && ((Mobile)o).Kills >= 5)
               {
               ((Mobile)o).Criminal = true;
                }
      if( o is Mobile && ((Mobile)o).GuildTitle != null )
               {
          ((Mobile)o).DisplayGuildTitle = true;
                }
      base.OnRemoved( o );
      }

      public ThievesCloak( 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();
      }

   }
}

hope that helps
  Reply With Quote
Old 06-02-2004, 08:58 AM   #10 (permalink)
Forum Expert
 
Captain The First's Avatar
 
Join Date: Jun 2003
Location: The Netherlands
Posts: 647
Default

Is it just me or will that not work appropiately?

Should your current fame be 10001 your fame will be set to -100000 and once you remove it you'll end up having 12000 fame.

Alternatively you could have 10001 fame equip the robe, unlock your karma gain slightly above -100000 to say -99000 and then unequip. Your fame being higher than -100000 will cause the if statement in your onremove to no longer trigger leaving you with -99000 fame after de-equip.

Additionally I wouldn't dare to dream of what would happen if you would use this nice -100000 fame to gain in sacrifice by dumping it on a lich.


Just some thoughts that pop into my head when reading the script... I am not saying these are actual problems... but they could be :P
__________________
Captain The First
_________________

Undisclosed shard (status: building since Feb. 2003)
Captain The First is offline   Reply With Quote
Old 06-02-2004, 09:19 AM   #11 (permalink)
Zigler
Guest
 
Posts: n/a
Default

yes could be very exploitable.. but the players cant tell what there fame is.. could atler scafrice not to allow anything above so high.. could make it -1000000 instead, . and yes if they had 10001 they would be set to 12000.. but if they have 15000 theyll be set to 12000.. again theres no way to tell.. could make it so that every time they use the robe it drops to 9000 and doesnt return.. or write ina FameMod.. but again this is a bandaid, nothing more.. Its a start maybe someone with more time could finish it. might want to change the <= -100000 to higher number or what its set when hood is up to a lower number if you add this.. cause if they kill anything lol.. they wont get there fame back.. either way... can you sacrfice - fame? doesnt make since but *shrug* you can alter it other ways.. but *shrug* I am tired lol
  Reply With Quote
Old 06-07-2004, 03:47 AM   #12 (permalink)
 
Join Date: Dec 2003
Posts: 22
Default Just a thought

If this is a thieves robe, how many thieves would have a lord/lady title? Maybe the solution is to make it unequipable to those with 10000 fame or higher. I like script and would make that change if I impliment it.
flashgordon is offline   Reply With Quote
Old 06-07-2004, 12:41 PM   #13 (permalink)
Forum Expert
 
Join Date: Dec 2003
Age: 35
Posts: 462
Send a message via ICQ to dstarz20 Send a message via AIM to dstarz20
Default

Well, the cloak does this for any person. As you know, the only reason it's called the thieve's cloak is becasue I add stealing +20, of course you could add anything.
dstarz20 is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 RC5