|
||
|
|||||||
| Network Modifications This forum is for modifications to the networking code of RunUO |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 (permalink) |
|
Forum Novice
|
when someone delete a character in the list remain a "hole", with this modification we solve the problem. Let's start the editing from Packet.cs in the core files.
after line 2922, exactly after this: Code:
for ( int i = 0; i < a.Length; ++i )
{
if ( a != null )
highSlot = i;
}
and after line 2891, exactly after this: Code:
m_Stream.Write( (byte) a.Count ); Code:
// Sort for update list by Keldron Isenhart
for ( int i = 0; i < a.Length; ++i )
{
for ( int j = i; j < a.Length; ++j )
{
if (a==null)
{
a=a[j];
a[j]=null;
}
}
}
//end sort
![]() |
|
|
|
|
|
#2 (permalink) |
|
UO Gamers: Demise Administrator
Join Date: Oct 2002
Location: Swamp
Age: 28
Posts: 10,636
|
Hehehe. OSI still has the "hole" problem as well.
You should send this fix in to them ^_^ (j/k, of course)
__________________
psz Demise' Creator (Retired) The RunUO.com Forum Moderator Team Former Official RunUO Scripter (Retired) Websites: My 360 Blog My Gaming Site(Old Link) My Gaming Site(New Link) |
|
|
|
|
|
#6 (permalink) |
|
Forum Expert
Join Date: Jul 2005
Location: Istanbul/Turkey
Age: 27
Posts: 425
|
are you sure that code is correct
![]() i think this is what you meant: Code:
for ( int i = 0; i < a.Length; ++i )
{
if (a[i] == null)
{
for ( int j = i+1; j < a.Length; ++j )
{
if (a[j] != null)
{
for(int k=i; j<a.Length; k++,j++)
{
a[k]=a[j];
a[j]=null;
}
break;
}
}
}
}
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|