Updating UltimaStore.cs

danielsheep

Gold Donator
Mar 19, 2018
126
4
18
Donate
Donate money to this user
Hello guys.
I am trying to update newest Ultima Store like OSI these days.
Several Items already has been included in servuo scripts.
Howerver, these new images does not display on the store gump.
The script definition value of the newly created decoration item has changed and will not be shown in the store when you add a script.
After looking at these issues, I concluded that some definitions of items displayed in the Ultimastore.cs file may need to be added.

For example, the definition value of houseladder.cs and the newly added definition of metalladder.cs
may not be able to bring up a gump image from ultimastore.cs because the 'int' definition is missing.

In the HouseLadder.cs

C#:
public class HouseLadderAddon : BaseAddon
    {
        public override BaseAddonDeed Deed { get { return new HouseLadderDeed(); } }

        [Constructable]
        public HouseLadderAddon(int type)
            : base()
        {
            switch (type)
In the MetalLadder.cs

C#:
    public class MetalLadderAddon : BaseAddon, IDyable
    {
        public override BaseAddonDeed Deed { get { return new MetalLadderDeed(); } }

        [Constructable]
        public MetalLadderAddon(MetalLadderType type)
        {
            switch (type)
in the UltimaStore.cs. There is no definition about "public MetalLadderAddon(MetalLadderType type)"

C#:
        public static void Register<T>(TextDefinition name, int tooltip, int itemID, int gumpID, int hue, int cost, StoreCategory cat, Func<Mobile, StoreEntry, Item> constructor = null) where T : Item
        {
            Register(typeof(T), name, tooltip, itemID, gumpID, hue, cost, cat, constructor);
        }    
        public static void Register(Type itemType, TextDefinition name, int tooltip, int itemID, int gumpID, int hue, int cost, StoreCategory cat, Func<Mobile, StoreEntry, Item> constructor = null)
        {
            Register(new StoreEntry(itemType, name, tooltip, itemID, gumpID, hue, cost, cat, constructor));
        }

        public static void Register<T>(TextDefinition[] name, int tooltip, int itemID, int gumpID, int hue, int cost, StoreCategory cat, Func<Mobile, StoreEntry, Item> constructor = null) where T : Item
        {
            Register(typeof(T), name, tooltip, itemID, gumpID, hue, cost, cat, constructor);
        }

        public static void Register(Type itemType, TextDefinition[] name, int tooltip, int itemID, int gumpID, int hue, int cost, StoreCategory cat, Func<Mobile, StoreEntry, Item> constructor = null)
        {
            Register(new StoreEntry(itemType, name, tooltip, itemID, gumpID, hue, cost, cat, constructor));
        }

        public static void Register(StoreEntry entry)
        {
            Entries.Add(entry);
        }
I think the missing definition 'public MetalLadderAddon(MetalLadderType type)' is the reason why store gump cannot read an image of Metal Ladder.
If I'm right, I look forward to the help of someone who knows the line to be added to Ultimastore.cs.
Thank you and have a nice day.
 

Holyblablabla

Citizen
Jul 3, 2020
11
2
3
hi,danielsheep. its pleasant to find someone trying to duplicate the OSI vendor settings. im a noob and cannot help you.

however, i find the banker in royal city is absent...i searched and found nothing directly related in this forum.The most related post is yours. Is there a vendor gump that i can call up to add a banker manually?

Post automatically merged:

hi,danielsheep. its pleasant to find someone trying to duplicate the OSI vendor settings. im a noob and cannot help you.

however, i find the banker in royal city is absent...i searched and found nothing directly related in this forum.The most related post is yours. Is there a vendor gump that i can call up to add a banker manually?
:) seems i find the method. its just like the normal way of adding a simple spawner(https://runuo.net/wiki/index.php?title=XML_Spawner).

.add xmlspawner
target a position
enter "banker" in the blank place
done
 
Last edited: