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!

xml error with distro

This is the error i get

Scripts: Compiling C# scripts...failed (1 errors, 0 warnings)
Errors:
+ Customs/Xml/XmlMobiles/TalkingJeweler.cs:
CS1715: Line 10: 'Server.Mobiles.TalkingJeweler.SBInfos': type must be 'Syst
em.Collections.Generic.List<Server.Mobiles.SBInfo>' to match overridden member '
Server.Mobiles.BaseVendor.SBInfos'
CS0534: Line 7: 'Server.Mobiles.TalkingJeweler' does not implement inherited
abstract member 'Server.Mobiles.BaseVendor.SBInfos.get'
Scripts: One or more scripts failed to compile or no script files were found.
- Press return to exit, or R to try again.

this is the script


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

TheNorthStar

Sorceror
Ahh, you're using the old ArrayLists. RunUO vendors were changed over to Generic Lists some time ago.
Add this at the top
Code:
using System.Collections.Generic;

Replace:
Code:
private ArrayList m_SBInfos = new ArrayList();
protected override ArrayList SBInfos{ get { return m_SBInfos; } }
With:
Code:
        private List<SBInfo> m_SBInfos = new List<SBInfo>();
        protected override List<SBInfo> SBInfos{ get { return m_SBInfos; } }
 
ok now i got this


Scripts: Compiling C# scripts...failed (3 errors, 0 warnings)
Errors:
+ Customs/Xml/XmlQuest/XmlQuestHolder.cs:
CS0117: Line 360: 'Server.Network.NetState' does not contain a definition fo
r 'IsPost6017'
+ Customs/Xml/XmlUtils/WriteMulti.cs:
CS0246: Line 307: The type or namespace name 'Tile' could not be found (are
you missing a using directive or an assembly reference?)
CS0029: Line 307: Cannot implicitly convert type 'Server.StaticTile[]' to 'T
ile[]'
+ Customs/Xml/XmlSpawner2.cs:
CS0234: Line 9785: The type or namespace name 'Tile' does not exist in the n
amespace 'Server' (are you missing an assembly reference?)
CS0117: Line 9785: 'Server.Map' does not contain a definition for 'GetTilesA
t'
CS0030: Line 9790: Cannot convert type 'Server.Tile' to 'object'
CS0246: Line 9793: The type or namespace name 'Tile' could not be found (are
you missing a using directive or an assembly reference?)
CS0246: Line 9795: The type or namespace name 'Tile' could not be found (are
you missing a using directive or an assembly reference?)
CS0246: Line 9795: The type or namespace name 'Tile' could not be found (are
you missing a using directive or an assembly reference?)
CS0246: Line 9901: The type or namespace name 'Tile' could not be found (are
you missing a using directive or an assembly reference?)
CS0246: Line 9940: The type or namespace name 'Tile' could not be found (are
you missing a using directive or an assembly reference?)
CS0029: Line 9940: Cannot implicitly convert type 'Server.StaticTile[]' to '
Tile[]'
CS0246: Line 10065: The type or namespace name 'Tile' could not be found (ar
e you missing a using directive or an assembly reference?)
CS0246: Line 10096: The type or namespace name 'Tile' could not be found (ar
e you missing a using directive or an assembly reference?)
CS0029: Line 10096: Cannot implicitly convert type 'Server.StaticTile[]' to
'Tile[]'
CS0246: Line 10101: The type or namespace name 'Tile' could not be found (ar
e you missing a using directive or an assembly reference?)
Scripts: One or more scripts failed to compile or no script files were found.


Sry im completely new to this
 

TheNorthStar

Sorceror
for the "Tile" errors you need to go through and replace "Tile" with "StaticTile" or "LandTile". Most likely StaticTile, but you need to check.
"GetTilesAt" has been removed from Map.cs, so you will need to edit that out
"IsPost6017" was also replaced, you will have to either replace, or remove this check as well. It could just be replaced with "true", but that's not the best solution. ( instead of if(state.IsPost6017()), just have if(true) ) that would make it just follow that path always.

If you're new to this I would recommend using a different package, these edits are a bit trickier.
 
Top