|
||
|
|||||||
| FAQ Forum A place to find answers to the most frequently asked questions, and a place to post said answers. Do NOT use this forum to ask questions. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 (permalink) |
|
Forum Novice
Join Date: Aug 2004
Location: Quebec
Age: 20
Posts: 235
|
This is a small tutorial to help you to add a new props on PlayerMobile
Open this file: Scripts\Mobiles\PlayerMobile.cs Find the part of code: Code:
private int m_Profession; Code:
private int m_Newprop; Code:
[CommandProperty( AccessLevel.GameMaster )]
public bool PublicMyRunUO
{
get{ return GetFlag( PlayerFlag.PublicMyRunUO ); }
set{ SetFlag( PlayerFlag.PublicMyRunUO, value ); InvalidateMyRunUO(); }
}
Code:
[CommandProperty( AccessLevel.GameMaster )]
public NewProp int
{
get{ return m_Newprop; }
set{ m_Newprop = value; }
}
Code:
writer.Write( (int) X ); // version Code:
writer.Write( (int) X+1 ); // version Code:
writer.Write( (int) m_Newprop ); Code:
case X:
{
And the second X must be your version number. Code:
case X+1:
{
m_Newprop = reader.ReadInt();
goto case X;
}
If you want to correct me or add some stuffs, please contact me in PM. (Thanks Irian)
__________________
Airwalk Web Programmer RunUO THE best UO Emulator The first step to getting the things you want out of life is this: Decide what you want. - Ben Stein Last edited by airwalk; 02-14-2006 at 05:09 PM. |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|