RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

XMLSpawner errors no idea why???

jayates

Sorceror
Errors:
XmlMobiles/TalkingJeweler.cs:
CS1715: Line 10: 'Server.Mobiles.TalkingJeweler.SBInfos': type must be 'System.Collections.Generic.List<Server.Mobiles.SBInfo>'to match overridden member' Server.Mobiles.BaseVendor.SBInfos'
CS0534: Line 7: 'Server.Mobiles.TalkingJeweler' does not implemet inherited abstract member 'Server.Mobiles.BaseVendor.SBInfos.get'

Pleas help me somebody...... I have no idea why or how to fix it.
 
Then I think the issue is because, during the development from 2.0 to 2.1, there was a switch in favour of generic lists.

Solution: you have to do the opposite in XMLspawner (but I don't know how),
or you have to use RunUO 2.1
 

Grevenler

Wanderer
adding 'using System.Collections.Generic;' doesn't work, because the line wit the error is an ArrayList...

this is the code of the problem

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

namespace Server.Mobiles
{
    public class TalkingJeweler : TalkingBaseVendor
    {
        private ArrayList m_SBInfos = new ArrayList();
        protected override ArrayList SBInfos{ get { return m_SBInfos; } }

        [Constructable]
        public TalkingJeweler() : base( "the jeweler" )
        {
            SetSkill( SkillName.ItemID, 64.0, 100.0 );
        }

        public override void InitSBInfo()
        {
            m_SBInfos.Add( new SBJewel() );
        }

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

the error is in the method

'protected override ArrayList SBInfos{ get { return m_SBInfos; } }'

and the overrided method in BaseVendor.cs is a 'List<SBInfo>', but if i just change it in this script, a major list of error appears... =/

I hope that someone can help me with this.
 

Jeff

Lord
THe problems is... when i do that... More errors appear...
The compiler works in passes, so fixing 1 error might let 1 pass continue, in which a new pass shows different/newer errors that can be found. Just because you have MORE errors after fixing something, doesnt necessarily mean you fix was wrong.
 

Grevenler

Wanderer
With RunUO 2.1

and recently i discovered that the problem not only is the ArrayList to Lisr<SBInfo>... now in 2.1 the Tile class is missing, and that the source of other problems =/
 

Archfiend

Sorceror
I have this problem too. I'm using RunUO 2.1

The problem also shows up when I try to use Lokai Abilities System 1.5

I fixed the Lokai System partially... it runs but, the NPCs I removed ArrayList from, to replace with <SBInfo> don't seem to be able to show their sales list anymore.

I don't know if I'm desperate enough to modify all of XML Spawner's ArrayLists to have a partially working bunch of NPCs.

I think I'm going to revert to RunUO 2.0 to fix the problem instead...

Will Stygian Abyss 2D client work with it though... ?
 
Top