🆙 added Backgrounds to the renderer

This commit is contained in:
duckietm
2025-05-20 14:16:05 +02:00
parent e0c0c06c99
commit 7c40e69c75
10 changed files with 157 additions and 3 deletions
@@ -7,6 +7,9 @@ export class RoomUnitInfoParser implements IMessageParser
private _gender: string;
private _motto: string;
private _achievementScore: number;
private _backgroundId: number;
private _standId: number;
private _overlayId: number;
public flush(): boolean
{
@@ -15,6 +18,9 @@ export class RoomUnitInfoParser implements IMessageParser
this._gender = 'M';
this._motto = null;
this._achievementScore = 0;
this._backgroundId = 0;
this._standId = 0;
this._overlayId = 0;
return true;
}
@@ -56,4 +62,19 @@ export class RoomUnitInfoParser implements IMessageParser
{
return this._achievementScore;
}
}
public get backgroundId(): number
{
return this._backgroundId;
}
public get standId(): number
{
return this._standId;
}
public get overlayId(): number
{
return this._overlayId;
}
}
@@ -27,6 +27,9 @@ export class RoomUnitParser implements IMessageParser
const id = wrapper.readInt();
const username = wrapper.readString();
const custom = wrapper.readString();
const background = wrapper.readInt();
const stand = wrapper.readInt();
const overlay = wrapper.readInt();
let figure = wrapper.readString();
const roomIndex = wrapper.readInt();
const x = wrapper.readInt();
@@ -40,6 +43,9 @@ export class RoomUnitParser implements IMessageParser
user.dir = direction;
user.name = username;
user.custom = custom;
user.background = background;
user.stand = stand;
user.overlay = overlay;
user.x = x;
user.y = y;
user.z = z;
@@ -14,6 +14,9 @@ export class UserMessageData
private _figure: string = '';
private _custom: string = '';
private _activityPoints: number = 0;
private _background: number = 0;
private _stand: number = 0;
private _overlay: number = 0
private _webID: number = 0;
private _groupID: number = 0;
private _groupStatus: number = 0;
@@ -178,6 +181,36 @@ export class UserMessageData
this._activityPoints = k;
}
}
public get background(): number
{
return this._background;
}
public set background(k: number)
{
this._background = k;
}
public get stand(): number
{
return this._stand;
}
public set stand(k: number)
{
this._stand = k;
}
public get overlay(): number
{
return this._overlay;
}
public set overlay(k: number)
{
this._overlay = k;
}
public get webID(): number
{