How To: Generating Stealable Items

Discussion in 'XmlSpawner Development' started by Chris, Jun 17, 2014.

  1. Chris

    Chris Renaissance Staff
    Renaissance Staff

    May 14, 2012
    Likes Received:
    Making an existing item stealable:
    to make something stealable, you dont actually have to make any modifications to the item's script (although you can if you want).

    You can do it manually by issuing the [stealable command

    [stealable true

    and target an object. This sets the stealable flag on it. To check to see whether something is stealable just issue the command without an argument


    Spawning items as stealable:
    to spawn something as stealable you would use the STEALABLE keyword, like this


    You can do this with anything. In your case, the bridle already has movable set to false in its script, but if you hadnt you could have spawned it as both immovable and stealable with


    Scripting stealables:
    You can also set the stealable flag in the script. Here is an example

      [FlipableAttribute( 0x1024, 0x1025 )] 
      public class StrangeShafts : Item
         public StrangeShafts() : base( 0x1024 )
            Movable = false;
         public StrangeShafts( 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(); 
    and this you can just spawn directly

    Creating stealables with just an itemid:
    note, you can actually create stealable rares without having to write any scripts at all. Just take the itemid you want (e.g. 3103 is a broken clock) and spawn it like

    static,3103/movable/false/STEALABLE/true/weight/5/name/a rare broken clock

    and now you have just created and spawned a rare stealable broken clock.

    This can be an easy way to make a lot of unique stealables without having to script them all.

    Original Document by ArteGordon - Modified for use on UO:Renaissance
    Original Article -
  2. It'sallALark

    It'sallALark Well-Known Member

    Nov 24, 2015
    Likes Received:
    I think we need more practice with this code!!

Share This Page