|
||
|
|||||||
| 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) |
|
Master of the Internet
|
i thought i would share this for all of you shard owners out there
(i have this posted is script support - so you may see it there too) As the owner of a shard - i feel i should be able to see all hidden players, even fellow admins, but they should not be able to see me so i came up with a fix it requires a slight edit to the playermobile.cs file but it does not cause a player wipe or anything just change: Code:
public override bool CanSee( Mobile m )
{
if ( m is PlayerMobile && ((PlayerMobile)m).m_VisList.Contains( this ) )
return true;
return base.CanSee( m );
}
Code:
public override bool CanSee( Mobile m )
{
if ( m is PlayerMobile && ((PlayerMobile)m).m_VisList.Contains( this ) )
return true;
//added by greywolf
string AccountName = "XXXXX";
string AccountPlayer = "aaa";
if ( this is PlayerMobile) AccountPlayer = Convert.ToString( this.Account);
if ( this is PlayerMobile && AccountPlayer == AccountName )
return true;
//end add
return base.CanSee( m );
}
this way - you can "spy" on anybody and they can not spy on you (the aaa is in there only to stop it from having a null pointer --- so just leave it as is) |
|
|
|
|
|
#2 (permalink) |
|
Master of the Internet
|
ooops - missed one thing in there - using it as it is works - except you see ALL items that are hidden - including internal map items and other junk lol
below is the full part fixed - just needed to add in a chack that is was a mobil you were looking at ![]() Code:
public override bool CanSee( Mobile m )
{
if ( m is PlayerMobile && ((PlayerMobile)m).m_VisList.Contains( this ) )
return true;
//added by greywolf
string AccountName = "XXXXX";
string AccountPlayer = "aaa";
if ( this is PlayerMobile) AccountPlayer = Convert.ToString( this.Account);
if ( this is PlayerMobile && AccountPlayer == AccountName && m is PlayerMobile )
return true;
//end add
return base.CanSee( m );
}
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|