Adding Dungeons.
So I have been trying to get my new dungeon to work for the last few hours. I have watched all the tutorials many times, and I just cant seem to get it working. If I remove the line of code from RealmManager.cs the Wserver doesn't crash anymore, but the portal doesn't work.
Here is what the error looks like: http :// imgur .com/ Tkc9OPs
As for all the code I have added
Shatters.cs
=using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using wServer.realm.entities;
using wServer.logic.loot;
namespace wServer.realm.worlds
{
public class Shatters : World
{
public Shatters()
{
Name = "Shatters";
Background = 0;
AllowTeleport = true;
base.FromWorldMap(typeof(RealmManager).Assembly.Ge tManifestResourceStream("wServer.realm.worlds.Shat ters.wmap"));
}
public override World GetInstance(ClientProcessor psr)
{
return RealmManager.AddWorld(new Shatters());
}
}
}
Player.cs
case 0x5050:
world = RealmManager.AddWorld(new Shatters()); break;
World.cs
public const int Shatters = -13;
RealmManager.cs
Worlds[World.Shatters] = new Shatters();
XML
<Object type="0x5049" id="Shatters Key">
<Class>Equipment</Class>
<Item/>
<RemoteTexture>
<Instance>draw</Instance>
<Id>105357490</Id>
</RemoteTexture>
<SlotType>10</SlotType>
<Description>Do you dare enter?</Description>
<Sound>use_key</Sound>
<Consumable/>
<Soulbound/>
<Activate id="Shatters Portal">Create</Activate>
</Object>
<Object type="0x5050" id="Shatters Portal">
<Class>Portal</Class>
<IntergamePortal/>
<DungeonName>The Shatters</DungeonName>
<RemoteTexture>
<Instance>draw</Instance>
<Id>5347860293877760</Id>
</RemoteTexture>
</Object>
Here is what the error looks like: http :// imgur .com/ Tkc9OPs
As for all the code I have added
Shatters.cs
=using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using wServer.realm.entities;
using wServer.logic.loot;
namespace wServer.realm.worlds
{
public class Shatters : World
{
public Shatters()
{
Name = "Shatters";
Background = 0;
AllowTeleport = true;
base.FromWorldMap(typeof(RealmManager).Assembly.Ge tManifestResourceStream("wServer.realm.worlds.Shat ters.wmap"));
}
public override World GetInstance(ClientProcessor psr)
{
return RealmManager.AddWorld(new Shatters());
}
}
}
Player.cs
case 0x5050:
world = RealmManager.AddWorld(new Shatters()); break;
World.cs
public const int Shatters = -13;
RealmManager.cs
Worlds[World.Shatters] = new Shatters();
XML
<Object type="0x5049" id="Shatters Key">
<Class>Equipment</Class>
<Item/>
<RemoteTexture>
<Instance>draw</Instance>
<Id>105357490</Id>
</RemoteTexture>
<SlotType>10</SlotType>
<Description>Do you dare enter?</Description>
<Sound>use_key</Sound>
<Consumable/>
<Soulbound/>
<Activate id="Shatters Portal">Create</Activate>
</Object>
<Object type="0x5050" id="Shatters Portal">
<Class>Portal</Class>
<IntergamePortal/>
<DungeonName>The Shatters</DungeonName>
<RemoteTexture>
<Instance>draw</Instance>
<Id>5347860293877760</Id>
</RemoteTexture>
</Object>
