#W# Source and Scripts added. Added Scripts/Settings.cs to expose some basic tweak able settings.
This commit is contained in:
parent
b51c58f514
commit
3045c83799
3512 changed files with 627673 additions and 0 deletions
536
Scripts/Items/Books/BaseBook.cs
Normal file
536
Scripts/Items/Books/BaseBook.cs
Normal file
|
|
@ -0,0 +1,536 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Text;
|
||||
using Server;
|
||||
using Server.ContextMenus;
|
||||
using Server.Network;
|
||||
using Server.Gumps;
|
||||
using Server.Multis;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BookPageInfo
|
||||
{
|
||||
private string[] m_Lines;
|
||||
|
||||
public string[] Lines
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Lines;
|
||||
}
|
||||
set
|
||||
{
|
||||
m_Lines = value;
|
||||
}
|
||||
}
|
||||
|
||||
public BookPageInfo()
|
||||
{
|
||||
m_Lines = new string[0];
|
||||
}
|
||||
|
||||
public BookPageInfo( params string[] lines )
|
||||
{
|
||||
m_Lines = lines;
|
||||
}
|
||||
|
||||
public BookPageInfo( GenericReader reader )
|
||||
{
|
||||
int length = reader.ReadInt();
|
||||
|
||||
m_Lines = new string[length];
|
||||
|
||||
for ( int i = 0; i < m_Lines.Length; ++i )
|
||||
m_Lines[i] = Utility.Intern( reader.ReadString() );
|
||||
}
|
||||
|
||||
public void Serialize( GenericWriter writer )
|
||||
{
|
||||
writer.Write( m_Lines.Length );
|
||||
|
||||
for ( int i = 0; i < m_Lines.Length; ++i )
|
||||
writer.Write( m_Lines[i] );
|
||||
}
|
||||
}
|
||||
|
||||
public class BaseBook : Item, ISecurable
|
||||
{
|
||||
private string m_Title;
|
||||
private string m_Author;
|
||||
private BookPageInfo[] m_Pages;
|
||||
private bool m_Writable;
|
||||
private SecureLevel m_SecureLevel;
|
||||
|
||||
[CommandProperty( AccessLevel.GameMaster )]
|
||||
public string Title
|
||||
{
|
||||
get { return m_Title; }
|
||||
set { m_Title = value; InvalidateProperties(); }
|
||||
}
|
||||
|
||||
[CommandProperty( AccessLevel.GameMaster )]
|
||||
public string Author
|
||||
{
|
||||
get { return m_Author; }
|
||||
set { m_Author = value; InvalidateProperties(); }
|
||||
}
|
||||
|
||||
[CommandProperty( AccessLevel.GameMaster )]
|
||||
public bool Writable
|
||||
{
|
||||
get { return m_Writable; }
|
||||
set { m_Writable = value; }
|
||||
}
|
||||
|
||||
[CommandProperty(AccessLevel.GameMaster)]
|
||||
public int PagesCount
|
||||
{
|
||||
get { return m_Pages.Length; }
|
||||
}
|
||||
|
||||
public BookPageInfo[] Pages
|
||||
{
|
||||
get { return m_Pages; }
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public BaseBook( int itemID ) : this( itemID, 20, true )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public BaseBook( int itemID, int pageCount, bool writable ) : this( itemID, null, null, pageCount, writable )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public BaseBook( int itemID, string title, string author, int pageCount, bool writable ) : base( itemID )
|
||||
{
|
||||
m_Title = title;
|
||||
m_Author = author;
|
||||
m_Writable = writable;
|
||||
|
||||
BookContent content = this.DefaultContent;
|
||||
|
||||
if ( content == null )
|
||||
{
|
||||
m_Pages = new BookPageInfo[pageCount];
|
||||
|
||||
for ( int i = 0; i < m_Pages.Length; ++i )
|
||||
m_Pages[i] = new BookPageInfo();
|
||||
}
|
||||
else
|
||||
{
|
||||
m_Pages = content.Copy();
|
||||
}
|
||||
}
|
||||
|
||||
// Intended for defined books only
|
||||
public BaseBook( int itemID, bool writable ) : base( itemID )
|
||||
{
|
||||
m_Writable = writable;
|
||||
|
||||
BookContent content = this.DefaultContent;
|
||||
|
||||
if ( content == null )
|
||||
{
|
||||
m_Pages = new BookPageInfo[0];
|
||||
}
|
||||
else
|
||||
{
|
||||
m_Title = content.Title;
|
||||
m_Author = content.Author;
|
||||
m_Pages = content.Copy();
|
||||
}
|
||||
}
|
||||
|
||||
public virtual BookContent DefaultContent{ get{ return null; } }
|
||||
|
||||
public BaseBook( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
[Flags]
|
||||
private enum SaveFlags
|
||||
{
|
||||
None = 0x00,
|
||||
Title = 0x01,
|
||||
Author = 0x02,
|
||||
Writable = 0x04,
|
||||
Content = 0x08
|
||||
}
|
||||
|
||||
public override void GetContextMenuEntries( Mobile from, List<ContextMenuEntry> list )
|
||||
{
|
||||
base.GetContextMenuEntries( from, list );
|
||||
SetSecureLevelEntry.AddTo( from, this, list );
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
BookContent content = this.DefaultContent;
|
||||
|
||||
SaveFlags flags = SaveFlags.None;
|
||||
|
||||
if ( m_Title != ( content == null ? null : content.Title ) )
|
||||
flags |= SaveFlags.Title;
|
||||
|
||||
if ( m_Author != ( content == null ? null : content.Author ) )
|
||||
flags |= SaveFlags.Author;
|
||||
|
||||
if ( m_Writable )
|
||||
flags |= SaveFlags.Writable;
|
||||
|
||||
if ( content == null || !content.IsMatch( m_Pages ) )
|
||||
flags |= SaveFlags.Content;
|
||||
|
||||
|
||||
|
||||
writer.Write( (int) 4 ); // version
|
||||
|
||||
writer.Write( (int)m_SecureLevel );
|
||||
|
||||
writer.Write( (byte) flags );
|
||||
|
||||
if ( (flags & SaveFlags.Title) != 0 )
|
||||
writer.Write( m_Title );
|
||||
|
||||
if ( (flags & SaveFlags.Author) != 0 )
|
||||
writer.Write( m_Author );
|
||||
|
||||
if ( (flags & SaveFlags.Content) != 0 )
|
||||
{
|
||||
writer.WriteEncodedInt( m_Pages.Length );
|
||||
|
||||
for ( int i = 0; i < m_Pages.Length; ++i )
|
||||
m_Pages[i].Serialize( writer );
|
||||
}
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadInt();
|
||||
|
||||
switch ( version )
|
||||
{
|
||||
case 4:
|
||||
{
|
||||
m_SecureLevel = (SecureLevel)reader.ReadInt();
|
||||
goto case 3;
|
||||
}
|
||||
case 3:
|
||||
case 2:
|
||||
{
|
||||
BookContent content = this.DefaultContent;
|
||||
|
||||
SaveFlags flags = (SaveFlags) reader.ReadByte();
|
||||
|
||||
if ( (flags & SaveFlags.Title) != 0 )
|
||||
m_Title = Utility.Intern( reader.ReadString() );
|
||||
else if ( content != null )
|
||||
m_Title = content.Title;
|
||||
|
||||
if ( (flags & SaveFlags.Author) != 0 )
|
||||
m_Author = reader.ReadString();
|
||||
else if ( content != null )
|
||||
m_Author = content.Author;
|
||||
|
||||
m_Writable = ( flags & SaveFlags.Writable ) != 0;
|
||||
|
||||
if ( (flags & SaveFlags.Content) != 0 )
|
||||
{
|
||||
m_Pages = new BookPageInfo[reader.ReadEncodedInt()];
|
||||
|
||||
for ( int i = 0; i < m_Pages.Length; ++i )
|
||||
m_Pages[i] = new BookPageInfo( reader );
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( content != null )
|
||||
m_Pages = content.Copy();
|
||||
else
|
||||
m_Pages = new BookPageInfo[0];
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
case 1:
|
||||
case 0:
|
||||
{
|
||||
m_Title = reader.ReadString();
|
||||
m_Author = reader.ReadString();
|
||||
m_Writable = reader.ReadBool();
|
||||
|
||||
if ( version == 0 || reader.ReadBool() )
|
||||
{
|
||||
m_Pages = new BookPageInfo[reader.ReadInt()];
|
||||
|
||||
for ( int i = 0; i < m_Pages.Length; ++i )
|
||||
m_Pages[i] = new BookPageInfo( reader );
|
||||
}
|
||||
else
|
||||
{
|
||||
BookContent content = this.DefaultContent;
|
||||
|
||||
if ( content != null )
|
||||
m_Pages = content.Copy();
|
||||
else
|
||||
m_Pages = new BookPageInfo[0];
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if ( version < 3 && ( Weight == 1 || Weight == 2 ) )
|
||||
Weight = -1;
|
||||
}
|
||||
|
||||
public override void AddNameProperty( ObjectPropertyList list )
|
||||
{
|
||||
if ( m_Title != null && m_Title.Length > 0 )
|
||||
list.Add( m_Title );
|
||||
else
|
||||
base.AddNameProperty( list );
|
||||
}
|
||||
|
||||
/*public override void GetProperties( ObjectPropertyList list )
|
||||
{
|
||||
base.GetProperties( list );
|
||||
|
||||
if ( m_Title != null && m_Title.Length > 0 )
|
||||
list.Add( 1060658, "Title\t{0}", m_Title ); // ~1_val~: ~2_val~
|
||||
|
||||
if ( m_Author != null && m_Author.Length > 0 )
|
||||
list.Add( 1060659, "Author\t{0}", m_Author ); // ~1_val~: ~2_val~
|
||||
|
||||
if ( m_Pages != null && m_Pages.Length > 0 )
|
||||
list.Add( 1060660, "Pages\t{0}", m_Pages.Length ); // ~1_val~: ~2_val~
|
||||
}*/
|
||||
|
||||
public override void OnSingleClick ( Mobile from )
|
||||
{
|
||||
LabelTo( from, "{0} by {1}", m_Title, m_Author );
|
||||
LabelTo( from, "[{0} pages]", m_Pages.Length );
|
||||
}
|
||||
|
||||
public override void OnDoubleClick ( Mobile from )
|
||||
{
|
||||
if ( m_Title == null && m_Author == null && m_Writable == true )
|
||||
{
|
||||
Title = "a book";
|
||||
Author = from.Name;
|
||||
}
|
||||
|
||||
from.Send( new BookHeader( from, this ) );
|
||||
from.Send( new BookPageDetails( this ) );
|
||||
}
|
||||
|
||||
public string ContentAsString
|
||||
{
|
||||
get
|
||||
{
|
||||
StringBuilder sb = new StringBuilder();
|
||||
|
||||
foreach( BookPageInfo bpi in this.m_Pages )
|
||||
{
|
||||
foreach( string line in bpi.Lines )
|
||||
{
|
||||
sb.AppendLine( line );
|
||||
}
|
||||
}
|
||||
|
||||
return sb.ToString();
|
||||
}
|
||||
}
|
||||
|
||||
public string[] ContentAsStringArray
|
||||
{
|
||||
get
|
||||
{
|
||||
List<string> lines = new List<string>();
|
||||
|
||||
foreach( BookPageInfo bpi in this.m_Pages )
|
||||
{
|
||||
lines.AddRange( bpi.Lines );
|
||||
}
|
||||
|
||||
return lines.ToArray();
|
||||
}
|
||||
}
|
||||
|
||||
public static void Initialize()
|
||||
{
|
||||
PacketHandlers.Register( 0xD4, 0, true, new OnPacketReceive( HeaderChange ) );
|
||||
PacketHandlers.Register( 0x66, 0, true, new OnPacketReceive( ContentChange ) );
|
||||
PacketHandlers.Register( 0x93, 99, true, new OnPacketReceive( OldHeaderChange ) );
|
||||
}
|
||||
|
||||
public static void OldHeaderChange( NetState state, PacketReader pvSrc )
|
||||
{
|
||||
Mobile from = state.Mobile;
|
||||
BaseBook book = World.FindItem( pvSrc.ReadInt32() ) as BaseBook;
|
||||
|
||||
if ( book == null || !book.Writable || !from.InRange( book.GetWorldLocation(), 1 ) || !book.IsAccessibleTo( from ) )
|
||||
return;
|
||||
|
||||
pvSrc.Seek( 4, SeekOrigin.Current ); // Skip flags and page count
|
||||
|
||||
string title = pvSrc.ReadStringSafe( 60 );
|
||||
string author = pvSrc.ReadStringSafe( 30 );
|
||||
|
||||
book.Title = Utility.FixHtml( title );
|
||||
book.Author = Utility.FixHtml( author );
|
||||
}
|
||||
|
||||
public static void HeaderChange( NetState state, PacketReader pvSrc )
|
||||
{
|
||||
Mobile from = state.Mobile;
|
||||
BaseBook book = World.FindItem( pvSrc.ReadInt32() ) as BaseBook;
|
||||
|
||||
if ( book == null || !book.Writable || !from.InRange( book.GetWorldLocation(), 1 ) || !book.IsAccessibleTo( from ) )
|
||||
return;
|
||||
|
||||
pvSrc.Seek( 4, SeekOrigin.Current ); // Skip flags and page count
|
||||
|
||||
int titleLength = pvSrc.ReadUInt16();
|
||||
|
||||
if ( titleLength > 60 )
|
||||
return;
|
||||
|
||||
string title = pvSrc.ReadUTF8StringSafe( titleLength );
|
||||
|
||||
int authorLength = pvSrc.ReadUInt16();
|
||||
|
||||
if ( authorLength > 30 )
|
||||
return;
|
||||
|
||||
string author = pvSrc.ReadUTF8StringSafe( authorLength );
|
||||
|
||||
book.Title = Utility.FixHtml( title );
|
||||
book.Author = Utility.FixHtml( author );
|
||||
}
|
||||
|
||||
public static void ContentChange( NetState state, PacketReader pvSrc )
|
||||
{
|
||||
Mobile from = state.Mobile;
|
||||
BaseBook book = World.FindItem( pvSrc.ReadInt32() ) as BaseBook;
|
||||
|
||||
if ( book == null || !book.Writable || !from.InRange( book.GetWorldLocation(), 1 ) || !book.IsAccessibleTo( from ) )
|
||||
return;
|
||||
|
||||
int pageCount = pvSrc.ReadUInt16();
|
||||
|
||||
if ( pageCount > book.PagesCount )
|
||||
return;
|
||||
|
||||
for ( int i = 0; i < pageCount; ++i )
|
||||
{
|
||||
int index = pvSrc.ReadUInt16();
|
||||
|
||||
if ( index >= 1 && index <= book.PagesCount )
|
||||
{
|
||||
--index;
|
||||
|
||||
int lineCount = pvSrc.ReadUInt16();
|
||||
|
||||
if ( lineCount <= 8 )
|
||||
{
|
||||
string[] lines = new string[lineCount];
|
||||
|
||||
for ( int j = 0; j < lineCount; ++j )
|
||||
if ( (lines[j] = pvSrc.ReadUTF8StringSafe()).Length >= 80 )
|
||||
return;
|
||||
|
||||
book.Pages[index].Lines = lines;
|
||||
}
|
||||
else
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#region ISecurable Members
|
||||
|
||||
[CommandProperty( AccessLevel.GameMaster )]
|
||||
public SecureLevel Level
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_SecureLevel;
|
||||
}
|
||||
set
|
||||
{
|
||||
m_SecureLevel = value;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
|
||||
public sealed class BookPageDetails : Packet
|
||||
{
|
||||
public BookPageDetails( BaseBook book ) : base( 0x66 )
|
||||
{
|
||||
EnsureCapacity( 256 );
|
||||
|
||||
m_Stream.Write( (int) book.Serial );
|
||||
m_Stream.Write( (ushort) book.PagesCount );
|
||||
|
||||
for ( int i = 0; i < book.PagesCount; ++i )
|
||||
{
|
||||
BookPageInfo page = book.Pages[i];
|
||||
|
||||
m_Stream.Write( (ushort) (i + 1) );
|
||||
m_Stream.Write( (ushort) page.Lines.Length );
|
||||
|
||||
for ( int j = 0; j < page.Lines.Length; ++j )
|
||||
{
|
||||
byte[] buffer = Utility.UTF8.GetBytes( page.Lines[j] );
|
||||
|
||||
m_Stream.Write( buffer, 0, buffer.Length );
|
||||
m_Stream.Write( (byte) 0 );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public sealed class BookHeader : Packet
|
||||
{
|
||||
public BookHeader( Mobile from, BaseBook book ) : base ( 0xD4 )
|
||||
{
|
||||
string title = book.Title == null ? "" : book.Title;
|
||||
string author = book.Author == null ? "" : book.Author;
|
||||
|
||||
byte[] titleBuffer = Utility.UTF8.GetBytes( title );
|
||||
byte[] authorBuffer = Utility.UTF8.GetBytes( author );
|
||||
|
||||
EnsureCapacity( 15 + titleBuffer.Length + authorBuffer.Length );
|
||||
|
||||
m_Stream.Write( (int) book.Serial );
|
||||
m_Stream.Write( (bool) true );
|
||||
m_Stream.Write( (bool) book.Writable && from.InRange( book.GetWorldLocation(), 1 ) );
|
||||
m_Stream.Write( (ushort) book.PagesCount );
|
||||
|
||||
m_Stream.Write( (ushort) (titleBuffer.Length + 1) );
|
||||
m_Stream.Write( titleBuffer, 0, titleBuffer.Length );
|
||||
m_Stream.Write( (byte) 0 ); // terminate
|
||||
|
||||
m_Stream.Write( (ushort) (authorBuffer.Length + 1) );
|
||||
m_Stream.Write( authorBuffer, 0, authorBuffer.Length );
|
||||
m_Stream.Write( (byte) 0 ); // terminate
|
||||
}
|
||||
}
|
||||
}
|
||||
47
Scripts/Items/Books/BlueBook.cs
Normal file
47
Scripts/Items/Books/BlueBook.cs
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BlueBook : BaseBook
|
||||
{
|
||||
|
||||
[Constructable]
|
||||
public BlueBook() : base( 0xFF2, 40, true )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public BlueBook( int pageCount, bool writable ) : base( 0xFF2, pageCount, writable )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public BlueBook( string title, string author, int pageCount, bool writable ) : base( 0xFF2, title, author, pageCount, writable )
|
||||
{
|
||||
}
|
||||
|
||||
// Intended for defined books only
|
||||
public BlueBook( bool writable ) : base( 0xFF2, writable )
|
||||
{
|
||||
}
|
||||
|
||||
public BlueBook( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.Write( (int)0 ); // version
|
||||
}
|
||||
}
|
||||
}
|
||||
46
Scripts/Items/Books/BrownBook.cs
Normal file
46
Scripts/Items/Books/BrownBook.cs
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BrownBook : BaseBook
|
||||
{
|
||||
[Constructable]
|
||||
public BrownBook() : base( 0xFEF )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public BrownBook( int pageCount, bool writable ) : base( 0xFEF, pageCount, writable )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public BrownBook( string title, string author, int pageCount, bool writable ) : base( 0xFEF, title, author, pageCount, writable )
|
||||
{
|
||||
}
|
||||
|
||||
// Intended for defined books only
|
||||
public BrownBook( bool writable ) : base( 0xFEF, writable )
|
||||
{
|
||||
}
|
||||
|
||||
public BrownBook( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.Write( (int)0 ); // version
|
||||
}
|
||||
}
|
||||
}
|
||||
297
Scripts/Items/Books/Defined/BlackthornWelcomeBook.cs
Normal file
297
Scripts/Items/Books/Defined/BlackthornWelcomeBook.cs
Normal file
|
|
@ -0,0 +1,297 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BlackthornWelcomeBook : RedBook
|
||||
{
|
||||
public static readonly BookContent Content = new BookContent
|
||||
(
|
||||
"A Welcome", "Lord Blackthorn",
|
||||
new BookPageInfo
|
||||
(
|
||||
" Greetings to you,",
|
||||
"new member of the",
|
||||
"Trusted.",
|
||||
" You now read these",
|
||||
"words because you",
|
||||
"have been deemed",
|
||||
"worthy to join the",
|
||||
"ranks of"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Britannia's defenders.",
|
||||
"Some will call you a",
|
||||
"betrayer of mankind, I",
|
||||
"say they are",
|
||||
"misguided. I call you",
|
||||
"a defender for Sosaria",
|
||||
"needs saving from",
|
||||
"itself."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
" The forces of order",
|
||||
"once ruled our world.",
|
||||
"Like a great",
|
||||
"darkness over our",
|
||||
"lives we lived under",
|
||||
"the oppressive watch",
|
||||
"of a king who",
|
||||
"dictated our actions"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"and passed judgement",
|
||||
"on our character. He",
|
||||
"suppressed our way of",
|
||||
"life by denying our",
|
||||
"freedom and the",
|
||||
"ability to determine",
|
||||
"who we are and what",
|
||||
"we stand for. Even"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"today in the absense",
|
||||
"of this man we still",
|
||||
"see the symbol of his",
|
||||
"tyranny, we watch his",
|
||||
"personal guards patrol",
|
||||
"the cities to",
|
||||
"intimidate us, and we",
|
||||
"feel his laws like a"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"vice on our lives.",
|
||||
" You are here",
|
||||
"because you choose to",
|
||||
"be free. Like many",
|
||||
"Britannians you have",
|
||||
"felt the opression of",
|
||||
"one man's ideas",
|
||||
"weighing down upon"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"you like chains. You",
|
||||
"have felt the embrace",
|
||||
"of fear, wondering if",
|
||||
"you face consequence",
|
||||
"for simply having",
|
||||
"ideas not in harmony",
|
||||
"with those forced upon",
|
||||
"you. You have seen"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"men fight and die for",
|
||||
"the principles of a",
|
||||
"zealot and wondered,",
|
||||
"'Who will fight for",
|
||||
"my principles should",
|
||||
"they be opposed?'",
|
||||
"You tire of living",
|
||||
"under the shadow of"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"dreams that do not",
|
||||
"belong to you. And",
|
||||
"most of all, you have",
|
||||
"wondered what you",
|
||||
"can do to live free.",
|
||||
" Your journey to",
|
||||
"freedom begins here.",
|
||||
" I, like you, once"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"desired my freedom",
|
||||
"from the limits placed",
|
||||
"on me. I watched in",
|
||||
"disgust as this world",
|
||||
"became engrossed with",
|
||||
"the preaching of",
|
||||
"virtue and none of the",
|
||||
"practice. I held my"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"convictions in check,",
|
||||
"fearful of the reaction",
|
||||
"of men blinded by",
|
||||
"belief. I forced",
|
||||
"myself to bury the",
|
||||
"very idealogy that",
|
||||
"made me an individual.",
|
||||
"I was fortunate that"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"a being of unique",
|
||||
"power and",
|
||||
"unimaginable",
|
||||
"intelligence saw",
|
||||
"through to the true",
|
||||
"person I was, the",
|
||||
"person I was meant to",
|
||||
"be. Exodus found"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"within me a man of",
|
||||
"free will,",
|
||||
"determination, and",
|
||||
"incomprehension for",
|
||||
"the plight of",
|
||||
"oppression forced on so",
|
||||
"many Britannians.",
|
||||
" Exodus has also"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"chosen you because of",
|
||||
"the strength of your",
|
||||
"character.",
|
||||
" Many of the men",
|
||||
"who were once my",
|
||||
"peers look upon me",
|
||||
"and see a betrayer of",
|
||||
"humanity. They"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"claim my newfound",
|
||||
"form is unnatural and",
|
||||
"wrong. Because they",
|
||||
"see the unknown in",
|
||||
"me, they show fear.",
|
||||
"They disapprove of",
|
||||
"my choices and in",
|
||||
"their ignorance see"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"evil. Yet I hide my",
|
||||
"true self no longer",
|
||||
"from these men. My",
|
||||
"thoughts and my",
|
||||
"personal morality have",
|
||||
"been liberated in the",
|
||||
"face of the oppression",
|
||||
"that once consumed me."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Where they see a",
|
||||
"man no longer human.",
|
||||
"I see a man that has",
|
||||
"not betrayed his",
|
||||
"humanity but has been",
|
||||
"freed from it. This",
|
||||
"is the power that has",
|
||||
"been granted to me by"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Exodus. I have been",
|
||||
"given my freedom. I",
|
||||
"have been released",
|
||||
"from my fears.",
|
||||
" Exodus will give",
|
||||
"you the power to",
|
||||
"conquer your fears as",
|
||||
"well."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
" When your fear",
|
||||
"of this world is gone,",
|
||||
"then the world truly",
|
||||
"belongs to you in a",
|
||||
"way it never has",
|
||||
"before. You, trusted",
|
||||
"one, will soon be given",
|
||||
"a gift. Your body,"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"like mine, will be",
|
||||
"enlightened and raised",
|
||||
"to a level no mortal",
|
||||
"can know. The power",
|
||||
"to control your own",
|
||||
"destiny will belong to",
|
||||
"you for the first time",
|
||||
"in your life."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
" You will, at long",
|
||||
"last, be cleansed of",
|
||||
"fear.",
|
||||
" Together, with the",
|
||||
"power of Exodus",
|
||||
"behind us, we shall",
|
||||
"finally wage war on",
|
||||
"the oppression that"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"once held us back",
|
||||
"from our full",
|
||||
"potential. We shall",
|
||||
"claim this world, and",
|
||||
"reshape it in an image",
|
||||
"of freedom for all of",
|
||||
"us. Those who once",
|
||||
"told you who you are"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"and how you should",
|
||||
"live will no longer be",
|
||||
"able to stand in the",
|
||||
"way of your free will.",
|
||||
"Many say you will",
|
||||
"be abandoning your",
|
||||
"humanity but in truth,",
|
||||
"you will be more than"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"human.",
|
||||
" You will be freed."
|
||||
)
|
||||
);
|
||||
|
||||
public override BookContent DefaultContent{ get{ return Content; } }
|
||||
|
||||
[Constructable]
|
||||
public BlackthornWelcomeBook() : base( false )
|
||||
{
|
||||
Hue = 0x89B;
|
||||
}
|
||||
|
||||
public BlackthornWelcomeBook( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.WriteEncodedInt( (int)0 ); // version
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
61
Scripts/Items/Books/Defined/BookContent.cs
Normal file
61
Scripts/Items/Books/Defined/BookContent.cs
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class BookContent
|
||||
{
|
||||
private string m_Title;
|
||||
private string m_Author;
|
||||
|
||||
private BookPageInfo[] m_Pages;
|
||||
|
||||
public string Title{ get{ return m_Title; } }
|
||||
public string Author{ get{ return m_Author; } }
|
||||
|
||||
public BookPageInfo[] Pages{ get{ return m_Pages; } }
|
||||
|
||||
public BookContent( string title, string author, params BookPageInfo[] pages )
|
||||
{
|
||||
m_Title = title;
|
||||
m_Author = author;
|
||||
m_Pages = pages;
|
||||
}
|
||||
|
||||
public BookPageInfo[] Copy()
|
||||
{
|
||||
BookPageInfo[] copy = new BookPageInfo[m_Pages.Length];
|
||||
|
||||
for ( int i = 0; i < copy.Length; ++i )
|
||||
copy[i] = new BookPageInfo( m_Pages[i].Lines );
|
||||
|
||||
return copy;
|
||||
}
|
||||
|
||||
public bool IsMatch( BookPageInfo[] cmp )
|
||||
{
|
||||
if ( cmp.Length != m_Pages.Length )
|
||||
return false;
|
||||
|
||||
for ( int i = 0; i < cmp.Length; ++i )
|
||||
{
|
||||
string[] a = m_Pages[i].Lines;
|
||||
string[] b = cmp[i].Lines;
|
||||
|
||||
if ( a.Length != b.Length )
|
||||
{
|
||||
return false;
|
||||
}
|
||||
else if ( a != b )
|
||||
{
|
||||
for ( int j = 0; j < a.Length; ++j )
|
||||
{
|
||||
if ( a[j] != b[j] )
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
129
Scripts/Items/Books/Defined/DrakovsJournal.cs
Normal file
129
Scripts/Items/Books/Defined/DrakovsJournal.cs
Normal file
|
|
@ -0,0 +1,129 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class DrakovsJournal : BlueBook
|
||||
{
|
||||
public static readonly BookContent Content = new BookContent
|
||||
(
|
||||
"Drakov's Journal", "Drakov",
|
||||
new BookPageInfo
|
||||
(
|
||||
"My Master",
|
||||
"",
|
||||
"This journal was",
|
||||
"found on one of",
|
||||
"our controllers. It",
|
||||
"seems he has lost",
|
||||
"faith in you. Know",
|
||||
"that he has been"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"dealth with and will",
|
||||
"never again speak",
|
||||
"ill of you or our",
|
||||
"cause.",
|
||||
" -Galzon"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"We have completted",
|
||||
"construction of the",
|
||||
"devices needed to",
|
||||
"build the clockwork",
|
||||
"overseers and minions",
|
||||
"as per the request of",
|
||||
"the Master. The",
|
||||
"gargoyles have been"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"most useful and their",
|
||||
"knowledge of the",
|
||||
"techniques for the",
|
||||
"construction of these",
|
||||
"creatures will serve",
|
||||
"us well.",
|
||||
" -----",
|
||||
"I am not one to"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"criticize the Master,",
|
||||
"but I believe he may",
|
||||
"have erred in his",
|
||||
"decision to destroy",
|
||||
"the wingless ones.",
|
||||
"Already our forces",
|
||||
"are weakened by the",
|
||||
"constant attacks of"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"the humans Their",
|
||||
"strength and",
|
||||
"unquestioning",
|
||||
"compliance would",
|
||||
"have made them very",
|
||||
"useful in the fight",
|
||||
"against the humans.",
|
||||
"But the Master felt"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"their presence to be",
|
||||
"an annoyance and",
|
||||
"a distraction to the",
|
||||
"winged ones. It was",
|
||||
"not difficult at all",
|
||||
"to remove them from",
|
||||
"this world. But now",
|
||||
"I fear without more"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"allies, willing or",
|
||||
"not, we stand",
|
||||
"little chance of",
|
||||
"defeating the foul",
|
||||
"humans from our",
|
||||
"lands. Perhaps if",
|
||||
"the Master had",
|
||||
"shown a little"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"mercy and forsight",
|
||||
"we would not be",
|
||||
"in such dire peril."
|
||||
)
|
||||
);
|
||||
|
||||
public override BookContent DefaultContent{ get{ return Content; } }
|
||||
|
||||
[Constructable]
|
||||
public DrakovsJournal() : base( false )
|
||||
{
|
||||
}
|
||||
|
||||
public DrakovsJournal( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.WriteEncodedInt( (int)0 ); // version
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
182
Scripts/Items/Books/Defined/FropozJournal.cs
Normal file
182
Scripts/Items/Books/Defined/FropozJournal.cs
Normal file
|
|
@ -0,0 +1,182 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class FropozJournal : RedBook
|
||||
{
|
||||
public static readonly BookContent Content = new BookContent
|
||||
(
|
||||
"Journal", "Fropoz",
|
||||
new BookPageInfo
|
||||
(
|
||||
"I have done as my",
|
||||
"Master has",
|
||||
"instructed me.",
|
||||
"",
|
||||
"The painted humans",
|
||||
"have been driven into",
|
||||
"Britannia and are even",
|
||||
"now wreaking havoc"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"across the land,",
|
||||
"providing us with the",
|
||||
"distraction my Master",
|
||||
"requested. We",
|
||||
"have provided them",
|
||||
"with the masks",
|
||||
"necessary to defeat",
|
||||
"the orcs, thus"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"causing even more",
|
||||
"distress for the people",
|
||||
"of Britannia. The",
|
||||
"unsuspecting fools",
|
||||
"are too busy dealing",
|
||||
"with the orc hordes to",
|
||||
"continue their",
|
||||
"exploration of our"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"lands. We are",
|
||||
"safe...for now.",
|
||||
" ----",
|
||||
"The attacks",
|
||||
"continue exactly as",
|
||||
"planned. My Master",
|
||||
"is pleased with my",
|
||||
"work and we are"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"closer to our goals than",
|
||||
"ever before. The",
|
||||
"gargoyles have proven",
|
||||
"to be more troublesome",
|
||||
"than we first",
|
||||
"anticipated, but I",
|
||||
"believe we can",
|
||||
"subjugate them fully"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"given enough time. It's",
|
||||
"unfortunate that we",
|
||||
"did not discover their",
|
||||
"knowledge sooner.",
|
||||
"Even now they",
|
||||
"prepare our armies",
|
||||
"for battle, but not",
|
||||
"without resistance."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Now that some of",
|
||||
"them know of the",
|
||||
"other lands and of",
|
||||
"humans, they will",
|
||||
"double their efforts to",
|
||||
"seek help. This",
|
||||
"cannot be allowed.",
|
||||
" -----"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Damn them!! The",
|
||||
"humans proved",
|
||||
"more resourcefull than",
|
||||
"we thought them",
|
||||
"capable of. Already",
|
||||
"their homes are free",
|
||||
"of orcs and savages",
|
||||
"and they once again"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"are treading in our",
|
||||
"lands. We may have to",
|
||||
"move sooner than we",
|
||||
"thought. I will",
|
||||
"prepar my brethern",
|
||||
"and our golems.",
|
||||
"Hopefully, we can",
|
||||
"buy our Master some"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"more time before the",
|
||||
"humans discover us.",
|
||||
" -----",
|
||||
"It's too late. The",
|
||||
"gargoyles whom have",
|
||||
"evaded our capture",
|
||||
"have opened the doors",
|
||||
"to our land."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"They pray the",
|
||||
"humans will help",
|
||||
"them, despite the",
|
||||
"actions of their",
|
||||
"cousins in Britannia. I",
|
||||
"fear they are right.",
|
||||
"I must go to warn",
|
||||
"the MastKai Hohiro,"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"10.11.2001",
|
||||
"first one to be here",
|
||||
"",
|
||||
"Congrats. I didn't really",
|
||||
"care to log on earlier,",
|
||||
"nor did I come straight",
|
||||
"here. 2pm, Magus"
|
||||
)
|
||||
);
|
||||
|
||||
public override BookContent DefaultContent{ get{ return Content; } }
|
||||
|
||||
[Constructable]
|
||||
public FropozJournal() : base( false )
|
||||
{
|
||||
}
|
||||
|
||||
public override void AddNameProperty( ObjectPropertyList list )
|
||||
{
|
||||
list.Add( "Fropoz's Journal" );
|
||||
}
|
||||
|
||||
public override void OnSingleClick( Mobile from )
|
||||
{
|
||||
LabelTo( from, "Fropoz's Journal" );
|
||||
}
|
||||
|
||||
public FropozJournal( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.WriteEncodedInt( (int)0 ); // version
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
267
Scripts/Items/Books/Defined/KaburJournal.cs
Normal file
267
Scripts/Items/Books/Defined/KaburJournal.cs
Normal file
|
|
@ -0,0 +1,267 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class KaburJournal : RedBook
|
||||
{
|
||||
public static readonly BookContent Content = new BookContent
|
||||
(
|
||||
"Journal", "Kabur",
|
||||
new BookPageInfo
|
||||
(
|
||||
"The campaign to slaughter",
|
||||
"the Meer goes well.",
|
||||
"Although they seem to",
|
||||
"oppose the forces of",
|
||||
"ours at every turn, we",
|
||||
"still defeat them in",
|
||||
"combat. Spies of the",
|
||||
"Meer have been found and"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"slain outside of the",
|
||||
"fortress of ours. The",
|
||||
"fools underestimate us.",
|
||||
"We have the power of",
|
||||
"Lord Exodus behind us.",
|
||||
"Soon they will learn to",
|
||||
"serve the Juka and I",
|
||||
"shall carry the head of"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"the wench, Dasha, on a",
|
||||
"spike for all the warriors",
|
||||
"of ours to share triumph",
|
||||
"under.",
|
||||
"",
|
||||
"One of the warriors of",
|
||||
"the Juka died today.",
|
||||
"During the training"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"exercises of ours he",
|
||||
"spoke out in favor of",
|
||||
"the warriors of the",
|
||||
"Meer, saying that they",
|
||||
"were indeed powerful and",
|
||||
"would provide a challenge",
|
||||
"to the Juka. A Juka in",
|
||||
"fear is no Juka. I gave"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"him the death of a",
|
||||
"coward, outside of battle.",
|
||||
"",
|
||||
"More spies of the Meer",
|
||||
"have been found around",
|
||||
"the fortress of ours.",
|
||||
"Many have been seen and",
|
||||
"escaped the wrath of the"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"warriors of ours. Those",
|
||||
"who have been captured",
|
||||
"and tortured have",
|
||||
"revealed nothing to us,",
|
||||
"even when subjected to",
|
||||
"the spells of the females.",
|
||||
" I know the Meer must",
|
||||
"have plans against us if"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"they send so many spies.",
|
||||
" I may send the troops",
|
||||
"of the Juka to invade",
|
||||
"the camps of theirs as a",
|
||||
"warning.",
|
||||
"",
|
||||
"I have met Dasha in",
|
||||
"battle this day. The"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"efforts of hers to draw",
|
||||
"me into a Black Duel",
|
||||
"were foolish. Had we",
|
||||
"not been interrupted in",
|
||||
"the cave I would have",
|
||||
"ended the life of hers",
|
||||
"but I will have to wait",
|
||||
"for another battle. Lord"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Exodus has ordered more",
|
||||
"patrols around the",
|
||||
"fortress of ours. If",
|
||||
"Dasha is any indication,",
|
||||
"the Meer will strike soon.",
|
||||
"",
|
||||
"More Meer stand outside",
|
||||
"of the fortress of ours"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"than I have ever seen at",
|
||||
"once. They must seek",
|
||||
"vengeance for the",
|
||||
"destruction of their",
|
||||
"forest. Many Juka stand",
|
||||
"ready at the base of the",
|
||||
"mountain to face the",
|
||||
"forces of theirs but"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"today may be the final",
|
||||
"battle. Exodus has",
|
||||
"summoned me, I must",
|
||||
"prepare.",
|
||||
"",
|
||||
"Dusk has passed and the",
|
||||
"Juka now live in a new",
|
||||
"age, a later time. I have"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"just returned from",
|
||||
"exploring the new world",
|
||||
"that surrounds the",
|
||||
"fortress of the Juka.",
|
||||
"During the attack of the",
|
||||
"Meer the madman",
|
||||
"Adranath tried to destroy",
|
||||
"the fortress of ours"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"with great magic. At",
|
||||
"once he was still and",
|
||||
"light surrounded the",
|
||||
"fortress. Everything",
|
||||
"faded from view. When I",
|
||||
"regained the senses of",
|
||||
"mine I saw no sign of",
|
||||
"the Meer but Dasha."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"She has not been found",
|
||||
"since this new being,",
|
||||
"Blackthorn, blasted her",
|
||||
"from the top of the",
|
||||
"fortress.",
|
||||
"The forest was gone, now",
|
||||
"replaced by grasslands.",
|
||||
"In the far distance I"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"could see humans that",
|
||||
"had covered the bodies of",
|
||||
"theirs in marks. Even",
|
||||
"Gargoyles populate this",
|
||||
"place. Exodus has",
|
||||
"explained to me that the",
|
||||
"Juka and the fortress of",
|
||||
"ours have been pulled"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"forward in time. The",
|
||||
"world we knew is now",
|
||||
"thousands of years in the",
|
||||
"past. Lord Exodus say",
|
||||
"he has has saved the",
|
||||
"Juka from extinction. I",
|
||||
"do not want to believe",
|
||||
"him. I asked this"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"stranger about the Meer,",
|
||||
"but he tells me a new",
|
||||
"enemy remains to be",
|
||||
"destroyed. It seems the",
|
||||
"enemies of ours have",
|
||||
"passed away to dust like",
|
||||
"the forest."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"I have spoken with other",
|
||||
"Juka and I suspect I have",
|
||||
"been told the truth. All",
|
||||
"the Juka had powerful",
|
||||
"dreams. In the dreams",
|
||||
"of ours the Meer invaded",
|
||||
"the fortress of ours and",
|
||||
"a great battle took place."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
" All the Juka and all the",
|
||||
"Meer perished and the",
|
||||
"fortress was destroyed",
|
||||
"from Adranath's spells. I",
|
||||
"would not like to believe",
|
||||
"that the Meer could ever",
|
||||
"destroy us, but now it",
|
||||
"seems we have seen a"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"vision of the fate of",
|
||||
"ours now lost in time. I",
|
||||
"must now wonder if the",
|
||||
"Meer did not die in the",
|
||||
"battle with the Juka, how",
|
||||
"did they die? And more",
|
||||
"importantly, where is",
|
||||
"Dasha?"
|
||||
)
|
||||
);
|
||||
|
||||
public override BookContent DefaultContent{ get{ return Content; } }
|
||||
|
||||
[Constructable]
|
||||
public KaburJournal() : base( false )
|
||||
{
|
||||
}
|
||||
|
||||
public override void AddNameProperty( ObjectPropertyList list )
|
||||
{
|
||||
list.Add( "Khabur's Journal" );
|
||||
}
|
||||
|
||||
public override void OnSingleClick( Mobile from )
|
||||
{
|
||||
LabelTo( from, "Khabur's Journal" );
|
||||
}
|
||||
|
||||
public KaburJournal( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.WriteEncodedInt( (int)0 ); // version
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
6211
Scripts/Items/Books/Defined/LibraryBooks.cs
Normal file
6211
Scripts/Items/Books/Defined/LibraryBooks.cs
Normal file
File diff suppressed because it is too large
Load diff
132
Scripts/Items/Books/Defined/NewAquariumBook.cs
Normal file
132
Scripts/Items/Books/Defined/NewAquariumBook.cs
Normal file
|
|
@ -0,0 +1,132 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class NewAquariumBook : BlueBook
|
||||
{
|
||||
public static readonly BookContent Content = new BookContent
|
||||
(
|
||||
"Your New Aquarium", "Les Bilgewater",
|
||||
new BookPageInfo
|
||||
(
|
||||
"Welcome to the",
|
||||
"wonderful world",
|
||||
"of aquarium ownership.",
|
||||
"With a little time and",
|
||||
"skill your aquarium can",
|
||||
"become a work of art!"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Catching Fish:",
|
||||
"You will need to",
|
||||
"aquire a fishing net,",
|
||||
"and a number of fish",
|
||||
"bowls, from your local",
|
||||
"fisherman.",
|
||||
"To use the net,",
|
||||
"select it from your"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"backpack, and cast it",
|
||||
"into shallow water.",
|
||||
"Then we wait.",
|
||||
" The fish will be so",
|
||||
"happy to be in your",
|
||||
"aquarium, they will",
|
||||
"jump right into your",
|
||||
"fish bowl when caught!"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Just take them home",
|
||||
"and pour them into",
|
||||
"your aquarium, and",
|
||||
"BING! You have a happy",
|
||||
"new addition to your",
|
||||
"collection!"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Caring for our",
|
||||
"Underwater Allies:",
|
||||
"",
|
||||
" Fish need clean",
|
||||
"water and food to",
|
||||
"survive.",
|
||||
" Our aquarium comes",
|
||||
"with a status monitoring"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"aid. Must be Magic!",
|
||||
" Just look at the",
|
||||
"front of your aquarium",
|
||||
"(mouse over). See the",
|
||||
"helpful and friendly",
|
||||
"guide? It tells how much",
|
||||
"food and water is",
|
||||
"needed to maintain,"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"and improve the quality",
|
||||
"of your tank.",
|
||||
" You dont want to",
|
||||
"overfeed your fish",
|
||||
"very often. In fact,",
|
||||
"you only want to feed",
|
||||
"them every other day.",
|
||||
"But, remember to keep"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"the water strong and",
|
||||
"healthy, and add more",
|
||||
"on a regular basis",
|
||||
"to keep your aquarium",
|
||||
"a pretty, sparkely blue.",
|
||||
"",
|
||||
" Well, I hope you",
|
||||
"get as much enjoyment,"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"collecting a beautiful",
|
||||
"array of our fine, finned,",
|
||||
"friends from the sea,",
|
||||
"as I do!",
|
||||
"",
|
||||
"Happy Fishing!"
|
||||
)
|
||||
);
|
||||
|
||||
public override BookContent DefaultContent{ get{ return Content; } }
|
||||
|
||||
[Constructable]
|
||||
public NewAquariumBook() : base( false )
|
||||
{
|
||||
Hue = 0;
|
||||
}
|
||||
|
||||
public NewAquariumBook( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.WriteEncodedInt( (int)0 ); // version
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
164
Scripts/Items/Books/Defined/TranslatedGargoyleJournal.cs
Normal file
164
Scripts/Items/Books/Defined/TranslatedGargoyleJournal.cs
Normal file
|
|
@ -0,0 +1,164 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class TranslatedGargoyleJournal : BlueBook
|
||||
{
|
||||
public static readonly BookContent Content = new BookContent
|
||||
(
|
||||
"Translated Journal", "Velis",
|
||||
new BookPageInfo
|
||||
(
|
||||
"This text has been",
|
||||
"translated from a",
|
||||
"gargoyle's journal",
|
||||
"following his capture",
|
||||
"and subsequent",
|
||||
"reeducation.",
|
||||
"",
|
||||
" -Velis"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"I write this in the",
|
||||
"hopes that someday a",
|
||||
"soul of pure heart and",
|
||||
"mind will read it. We",
|
||||
"are not the evil beings",
|
||||
"that our cousin",
|
||||
"gargoyles have made",
|
||||
"us out to be. We"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"consider them",
|
||||
"uncivilized and they",
|
||||
"have no concept of the",
|
||||
"Principles. To you",
|
||||
"who reads this, I beg",
|
||||
"for your help in",
|
||||
"saving my brethern",
|
||||
"and preserving my"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"race. We stand at the",
|
||||
"edge of destruction as",
|
||||
"does the rest of the",
|
||||
"world. Once it was",
|
||||
"written law that we",
|
||||
"would not allow the",
|
||||
"knowledge of our",
|
||||
"civilization to spread"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"into the world, no we",
|
||||
"are left with little",
|
||||
"choice...contact the",
|
||||
"outside world in the hopes",
|
||||
"of finding help to save",
|
||||
"it or becoming the",
|
||||
"unwilling bringers of",
|
||||
"its damnation."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
" I fear my capture is",
|
||||
"certain, the",
|
||||
"controllers grow ever",
|
||||
"closer to my hiding",
|
||||
"place and I know if",
|
||||
"they discover me, my",
|
||||
"fate will be as that of",
|
||||
"my brothers."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Although we resisted",
|
||||
"with all our strength",
|
||||
"it is now clear that we",
|
||||
"must have assistance",
|
||||
"or our people will be",
|
||||
"gone. And if our",
|
||||
"oppressor achieves",
|
||||
"his goals our race will"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"surely be joined buy",
|
||||
"others.",
|
||||
" Those of us who",
|
||||
"have not yet been",
|
||||
"taken hope to open a",
|
||||
"path from the outside",
|
||||
"world into the city.",
|
||||
"We believe we have"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"found weak areas in",
|
||||
"the mountains that we",
|
||||
"can successfully",
|
||||
"knock through with",
|
||||
"our limited supplies.",
|
||||
"We will have to work",
|
||||
"quickly and the risk",
|
||||
"of being discovered is"
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"great, but no choice",
|
||||
"remains..."
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
),
|
||||
new BookPageInfo
|
||||
(
|
||||
"Kai Hohiro, 12pm.",
|
||||
"10.11.2001",
|
||||
"first one to be here"
|
||||
)
|
||||
);
|
||||
|
||||
public override BookContent DefaultContent{ get{ return Content; } }
|
||||
|
||||
[Constructable]
|
||||
public TranslatedGargoyleJournal() : base( false )
|
||||
{
|
||||
}
|
||||
|
||||
public override void AddNameProperty( ObjectPropertyList list )
|
||||
{
|
||||
list.Add( "Translated Gargoyle Journal" );
|
||||
}
|
||||
|
||||
public override void OnSingleClick( Mobile from )
|
||||
{
|
||||
LabelTo( from, "Translated Gargoyle Journal" );
|
||||
}
|
||||
|
||||
public TranslatedGargoyleJournal( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.WriteEncodedInt( (int)0 ); // version
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadEncodedInt();
|
||||
}
|
||||
}
|
||||
}
|
||||
46
Scripts/Items/Books/RedBook.cs
Normal file
46
Scripts/Items/Books/RedBook.cs
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class RedBook : BaseBook
|
||||
{
|
||||
[Constructable]
|
||||
public RedBook() : base( 0xFF1 )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public RedBook( int pageCount, bool writable ) : base( 0xFF1, pageCount, writable )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public RedBook( string title, string author, int pageCount, bool writable ) : base( 0xFF1, title, author, pageCount, writable )
|
||||
{
|
||||
}
|
||||
|
||||
// Intended for defined books only
|
||||
public RedBook( bool writable ) : base( 0xFF1, writable )
|
||||
{
|
||||
}
|
||||
|
||||
public RedBook( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.Write( (int)0 ); // version
|
||||
}
|
||||
}
|
||||
}
|
||||
46
Scripts/Items/Books/TanBook.cs
Normal file
46
Scripts/Items/Books/TanBook.cs
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
using System;
|
||||
using Server;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
public class TanBook : BaseBook
|
||||
{
|
||||
[Constructable]
|
||||
public TanBook() : base( 0xFF0 )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public TanBook( int pageCount, bool writable ) : base( 0xFF0, pageCount, writable )
|
||||
{
|
||||
}
|
||||
|
||||
[Constructable]
|
||||
public TanBook( string title, string author, int pageCount, bool writable ) : base( 0xFF0, title, author, pageCount, writable )
|
||||
{
|
||||
}
|
||||
|
||||
// Intended for defined books only
|
||||
public TanBook( bool writable ) : base( 0xFF0, writable )
|
||||
{
|
||||
}
|
||||
|
||||
public TanBook( Serial serial ) : base( serial )
|
||||
{
|
||||
}
|
||||
|
||||
public override void Deserialize( GenericReader reader )
|
||||
{
|
||||
base.Deserialize( reader );
|
||||
|
||||
int version = reader.ReadInt();
|
||||
}
|
||||
|
||||
public override void Serialize( GenericWriter writer )
|
||||
{
|
||||
base.Serialize( writer );
|
||||
|
||||
writer.Write( (int)0 ); // version
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue