|
||
|
|||||||
| Custom Script Release Archive This is a pre-script database archive of what our users had released. |
|
|
Thread Tools | Display Modes |
|
|
#26 (permalink) |
|
Forum Novice
|
Thank you for taking the time to help me, I did as you stated, yet this error came up:
RunUO - [www.runuo.com] Version 2.0, Build 2357.32527 Core: Running on .NET Framework Version 2.0.50727 Core: Optimizing for 2 processors Scripts: Compiling C# scripts...failed (1 errors, 0 warnings) Errors: + Mobiles/PlayerMobile.cs: CS1514: Line 77: { expected CS1519: Line 91: Invalid token '{' in class, struct, or interface member dec laration Scripts: One or more scripts failed to compile or no script files were found. - Press return to exit, or R to try again. |
|
|
|
|
#27 (permalink) | |
|
Master of the Internet
Join Date: Aug 2003
Posts: 5,688
|
Quote:
__________________
The first line of the first rule in the forum rules and guidelines "Be respectful of others. " For questions, information, and support for XmlSpawner and its addons, visit the XmlSpawner Support Forum |
|
|
|
|
|
#28 (permalink) | |
|
Master of the Internet
Join Date: Aug 2003
Posts: 5,688
|
Quote:
__________________
The first line of the first rule in the forum rules and guidelines "Be respectful of others. " For questions, information, and support for XmlSpawner and its addons, visit the XmlSpawner Support Forum |
|
|
|
|
|
#30 (permalink) | |
|
Master of the Internet
Join Date: Aug 2003
Posts: 5,688
|
Quote:
Code:
public static DuelLocationEntry[] DuelLocations = new DuelLocationEntry[]
{
new DuelLocationEntry("Jhelom Fighting Pit", 1398, 3742, -21, Map.Felucca, 14),
new DuelLocationEntry("Luna Grand Arena", 940, 637, -90, Map.Malas, 4),
};
__________________
The first line of the first rule in the forum rules and guidelines "Be respectful of others. " For questions, information, and support for XmlSpawner and its addons, visit the XmlSpawner Support Forum |
|
|
|
|
|
#31 (permalink) |
|
Forum Expert
|
Hi Arte. Ran into a little problem when I restarted my server this afternoon, error report in debug mode:
Code:
RunUO - [www.runuo.com] Version 2.0, Build 2368.38595 Core: Running on .NET Framework Version 2.0.50727 Core: Running with arguments: -debug Scripts: Compiling C# scripts...done (0 errors, 0 warnings) Scripts: Compiling VB.NET scripts...no files found. Scripts: Verifying...done (2297 items, 569 mobiles) Regions: Loading...done World: Loading...An error was encountered while loading a saved object - Type: Server.Engines.XmlSpawner2.ChallengeRegionStone - Serial: 0x400149B5 Delete the object? (y/n) Delete all objects of that type? (y/n) After pressing return an exception will be thrown and the server will terminate Error: System.Exception: Load failed (items=True, mobiles=False, guilds=False, type=Ser ver.Engines.XmlSpawner2.ChallengeRegionStone, serial=0x400149B5) ---> System.Nul lReferenceException: Object reference not set to an instance of an object. at Server.Region.Register() at Server.Engines.XmlSpawner2.ChallengeRegionStone.RefreshRegions() in c:\Doc uments and Settings\Compaq_Owner\Desktop\RunUOShit\RunUO2SVN\Scripts\Customs\XML Points\ChallengeRegionStone.cs:line 148 at Server.Engines.XmlSpawner2.ChallengeRegionStone.Deserialize(GenericReader reader) in c:\Documents and Settings\Compaq_Owner\Desktop\RunUOShit\RunUO2SVN\Sc ripts\Customs\XMLPoints\ChallengeRegionStone.cs:line 282 at Server.World.Load() --- End of inner exception stack trace --- at Server.World.Load() at Server.ScriptCompiler.Compile(Boolean debug, Boolean cache) at Server.Core.Main(String[] args) This exception is fatal, press return to exit Code:
using System;
using Server;
using Server.Mobiles;
using Server.Items;
using Server.Regions;
using System.Collections;
namespace Server.Engines.XmlSpawner2
{
public class ChallengeRegionStone : Item
{
public Map m_ChallengeMap;
private string m_ChallengeRegionName;
private ChallengeGameRegion m_ChallengeRegion; // challenge region
private MusicName m_Music;
private int m_Priority;
private Rectangle3D [] m_ChallengeArea;
private string m_CopiedRegion;
private bool m_Disable;
[CommandProperty( AccessLevel.GameMaster )]
public Rectangle3D [] ChallengeArea
{
get { return m_ChallengeArea; }
set { m_ChallengeArea = value;}
}
[CommandProperty( AccessLevel.GameMaster )]
public bool DisableGuards
{
get { return m_Disable; }
set
{
m_Disable = value;
if(m_ChallengeRegion != null)
{
m_ChallengeRegion.Unregister();
m_ChallengeRegion.Disabled = m_Disable;
m_ChallengeRegion.Register();
}
}
}
[CommandProperty( AccessLevel.GameMaster )]
public string ChallengeRegionName
{
get { return m_ChallengeRegionName; }
set
{
m_ChallengeRegionName = value;
RefreshRegions();
}
}
[CommandProperty( AccessLevel.GameMaster )]
public ChallengeGameRegion ChallengeRegion
{
get { return m_ChallengeRegion; }
}
[CommandProperty( AccessLevel.GameMaster )]
public Map ChallengeMap
{
get { return m_ChallengeMap; }
set {
m_ChallengeMap = value;
RefreshRegions();
}
}
[CommandProperty( AccessLevel.GameMaster )]
public MusicName ChallengeMusic
{
get { return m_Music; }
set {
m_Music = value;
if(m_ChallengeRegion != null)
{
m_ChallengeRegion.Unregister();
m_ChallengeRegion.Music = m_Music;
m_ChallengeRegion.Register();
}
}
}
[CommandProperty( AccessLevel.GameMaster )]
public int ChallengePriority
{
get { return m_Priority; }
set {
m_Priority = value;
RefreshRegions();
}
}
[CommandProperty( AccessLevel.GameMaster )]
public string CopyRegion
{
get {
return m_CopiedRegion;
}
set {
if(value == null)
{
m_CopiedRegion = null;
} else
{
// find the named region
Region r = this.Map.Regions[value];
if(r != null)
{
m_CopiedRegion = value;
// copy the coords, map, and music from that region
m_ChallengeMap = r.Map;
m_Music = r.Music;
m_Priority = r.Priority;
m_ChallengeArea = r.Area;
RefreshRegions();
}
}
}
}
public void RefreshRegions()
{
if (m_ChallengeRegion != null)
{
m_ChallengeRegion.Unregister();
}
// define a new one based on the named region
m_ChallengeRegion = new ChallengeGameRegion(m_ChallengeRegionName, m_ChallengeMap, m_Priority, m_ChallengeArea);
// update the new region properties with current values
m_ChallengeRegion.Music = m_Music;
m_ChallengeRegion.Disabled = m_Disable;
m_ChallengeRegion.Register();
}
[Constructable]
public ChallengeRegionStone() : base ( 0xED4 )
{
Visible = false;
Movable = false;
Name = "Challenge Region Stone";
ChallengeRegionName = "Challenge Game Region";
ChallengePriority = 0x90; // high priority
m_ChallengeMap = this.Map;
}
public ChallengeRegionStone( Serial serial ) : base( serial )
{
}
public override void Serialize( GenericWriter writer )
{
base.Serialize( writer );
writer.Write( (int) 2 ); // version
// version 2
// updated for RunUO 2.0 region changes in 3D region coordinates
// version 1
writer.Write( m_Disable );
// version 0
writer.Write( (int)m_Music );
writer.Write( m_Priority );
// removed in version 2
//writer.Write(m_ChallengeArea);
writer.Write( m_ChallengeRegionName );
if (m_ChallengeMap != null)
{
writer.Write(m_ChallengeMap.Name);
}
else
{
writer.Write(String.Empty);
}
writer.Write( m_CopiedRegion );
// do the coord list
if (m_ChallengeRegion != null && m_ChallengeRegion.Area != null && m_ChallengeRegion.Area.Length > 0)
{
writer.Write(m_ChallengeRegion.Area.Length);
for (int i = 0; i < m_ChallengeRegion.Area.Length; i++)
{
writer.Write(m_ChallengeRegion.Area[i].Start);
writer.Write(m_ChallengeRegion.Area[i].End);
}
}
else
{
writer.Write((int)0);
}
}
public override void GetProperties(ObjectPropertyList list)
{
base.GetProperties(list);
list.Add( 1062613, m_ChallengeRegionName);
}
public override void Deserialize( GenericReader reader )
{
base.Deserialize( reader );
int version = reader.ReadInt();
m_ChallengeArea = new Rectangle3D[0];
switch ( version )
{
case 2:
case 1:
{
m_Disable = reader.ReadBool();
goto case 0;
}
case 0:
{
m_Music = (MusicName)reader.ReadInt();
m_Priority = reader.ReadInt();
if (version < 2)
{
// old region area
reader.ReadRect2D();
}
m_ChallengeRegionName = reader.ReadString();
string mapname = reader.ReadString();
try{
m_ChallengeMap = Map.Parse(mapname);
} catch {}
m_CopiedRegion = reader.ReadString();
// do the coord list
int count = reader.ReadInt();
if (count > 0)
{
// the old version used 2D rectangles for the region area. The new version uses 3D
if (version < 2)
{
Rectangle2D[] area = new Rectangle2D[count];
for (int i = 0; i < count; i++)
{
area[i] = reader.ReadRect2D();
}
m_ChallengeArea = Region.ConvertTo3D(area);
}
else
{
m_ChallengeArea = new Rectangle3D[count];
for (int i = 0; i < count; i++)
{
m_ChallengeArea[i] = new Rectangle3D(reader.ReadPoint3D(), reader.ReadPoint3D());
}
}
}
break;
}
}
// refresh the region
RefreshRegions();
}
public static Region FindRegion(string name)
{
if (Region.Regions == null) return null;
foreach (Region region in Region.Regions)
{
if (string.Compare(region.Name, name, true) == 0)
{
return region;
}
}
return null;
}
public override void OnDoubleClick( Mobile m )
{
if( m != null && m.AccessLevel >= AccessLevel.GameMaster)
{
m.SendMessage("Define the Challenge area");
DefineChallengeArea ( m );
}
}
public void DefineChallengeArea( Mobile m )
{
BoundingBoxPicker.Begin( m, new BoundingBoxCallback( ChallengeRegionArea_Callback ), this );
}
private static void ChallengeRegionArea_Callback( Mobile from, Map map, Point3D start, Point3D end, object state )
{
// assign these coords to the region
ChallengeRegionStone s = state as ChallengeRegionStone;
if (s != null && from != null)
{
s.m_ChallengeArea = new Rectangle3D[1];
s.m_ChallengeArea[0] = Region.ConvertTo3D(new Rectangle2D(start.X, start.Y, end.X - start.X + 1, end.Y - start.Y + 1));
s.m_ChallengeMap = map;
s.CopyRegion = null;
s.RefreshRegions();
}
}
public override void OnDelete()
{
if( m_ChallengeRegion != null )
m_ChallengeRegion.Unregister();
base.OnDelete();
}
}
}
__________________
In some cases stupid makes you win-Radwen Last edited by Johabius; 06-28-2006 at 03:29 PM. |
|
|
|
|
#32 (permalink) | |
|
Master of the Internet
Join Date: Aug 2003
Posts: 5,688
|
Quote:
(edit) there may some issue with registering regions during the world loads, so I would make this mod. Around line 282 at the end of the Deserialize method in challengeregionstone.cs, change this Code:
// refresh the region RefreshRegions(); } Code:
// refresh the region Timer.DelayCall(TimeSpan.Zero, new TimerCallback(RefreshRegions)); }
__________________
The first line of the first rule in the forum rules and guidelines "Be respectful of others. " For questions, information, and support for XmlSpawner and its addons, visit the XmlSpawner Support Forum Last edited by ArteGordon; 06-28-2006 at 03:30 PM. |
|
|
|
|
|
#33 (permalink) | |
|
Forum Expert
|
Quote:
*starts up server* Works like a charm, thank you! ![]()
__________________
In some cases stupid makes you win-Radwen |
|
|
|
|
|
#35 (permalink) | |
|
Master of the Internet
Join Date: Aug 2003
Posts: 5,688
|
Quote:
__________________
The first line of the first rule in the forum rules and guidelines "Be respectful of others. " For questions, information, and support for XmlSpawner and its addons, visit the XmlSpawner Support Forum |
|
|
|
|
|
#36 (permalink) |
|
Forum Newbie
Join Date: Oct 2004
Age: 20
Posts: 19
|
for example "Unable to set up CTFChallenge" when i use [CTFChallenge (this same error with others games). When i use [challenge i see error like "No XmlPoints support"
I make all steps in XMLpoints, and all steps in XMLspawner without steps 3rd,4th,5th,10th and 12th Last edited by Kolo; 06-29-2006 at 08:28 AM. |
|
|
|
|
#37 (permalink) | |
|
Master of the Internet
Join Date: Aug 2003
Posts: 5,688
|
Quote:
[addallpoints command and you should be set.
__________________
The first line of the first rule in the forum rules and guidelines "Be respectful of others. " For questions, information, and support for XmlSpawner and its addons, visit the XmlSpawner Support Forum |
|
|
|
|
|
#38 (permalink) | |
|
Forum Newbie
Join Date: Oct 2004
Age: 20
Posts: 19
|
Quote:
|
|
|
|
|
|
#41 (permalink) | |
|
Join Date: Mar 2006
Posts: 97
|
Was reading through Milt's new system and thought this was a good feature:
Quote:
|
|
|
|
|
|
#42 (permalink) | |
|
Master of the Internet
Join Date: Aug 2003
Posts: 5,688
|
Quote:
(edit) actually, one thought might be to add a voting system while participating in games that could be used to mark problem players. Their rating would be visible to game organizers and then they could decide whether they wanted them to participate without having the system explicitly block them and so could be used to self police players.
__________________
The first line of the first rule in the forum rules and guidelines "Be respectful of others. " For questions, information, and support for XmlSpawner and its addons, visit the XmlSpawner Support Forum Last edited by ArteGordon; 06-29-2006 at 10:16 PM. |
|
|
|
|
|
#43 (permalink) |
|
Master of the Internet
Join Date: Aug 2003
Posts: 5,688
|
New to version 1.24a updated 6/30/06 - updated ChallengeRegionStone.cs in the xmlpoints-20-v124a-1of2.zip package with a small fix for a deserialization problem with ChallengeRegions. (thanks to Johabius for pointing it out).
__________________
The first line of the first rule in the forum rules and guidelines "Be respectful of others. " For questions, information, and support for XmlSpawner and its addons, visit the XmlSpawner Support Forum |
|
|
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|