Skip to content

Commit 4753425

Browse files
Xav101Xav101
authored andcommitted
engine: mod_bmodel: Byte swap in clipnodes loader on big endian. Server now starts on mips-irix platforms.
1 parent 6cd717c commit 4753425

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

engine/common/mod_bmodel.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2744,10 +2744,10 @@ static void Mod_LoadClipnodes( dbspmodel_t *bmod )
27442744

27452745
for( i = 0; i < bmod->numclipnodes; i++, out++, in++ )
27462746
{
2747-
out->planenum = in->planenum;
2747+
out->planenum = LittleLong( in->planenum );
27482748

2749-
out->children[0] = (unsigned short)in->children[0];
2750-
out->children[1] = (unsigned short)in->children[1];
2749+
out->children[0] = LittleShort( (unsigned short)in->children[0] );
2750+
out->children[1] = LittleShort( (unsigned short)in->children[1] );
27512751

27522752
// Arguire QBSP 'broken' clipnodes
27532753
if( out->children[0] >= bmod->numclipnodes )

0 commit comments

Comments
 (0)