You've already forked Nitro_Render_V3
mirror of
https://github.com/duckietm/Nitro_Render_V3.git
synced 2026-06-19 15:06:20 +00:00
🆕 Card Background
This commit is contained in:
+2
-2
@@ -4,9 +4,9 @@ export class RoomUnitBackgroundComposer implements IMessageComposer<ConstructorP
|
||||
{
|
||||
private _data: ConstructorParameters<typeof RoomUnitBackgroundComposer>;
|
||||
|
||||
constructor(backgroundImage: number, backgroundStand: number, backgroundOverlay: number)
|
||||
constructor(backgroundImage: number, backgroundStand: number, backgroundOverlay: number, backgroundCard: number = 0)
|
||||
{
|
||||
this._data = [ backgroundImage, backgroundStand, backgroundOverlay ];
|
||||
this._data = [ backgroundImage, backgroundStand, backgroundOverlay, backgroundCard ];
|
||||
}
|
||||
|
||||
public getMessageArray()
|
||||
|
||||
@@ -10,6 +10,7 @@ export class RoomUnitInfoParser implements IMessageParser
|
||||
private _backgroundId: number;
|
||||
private _standId: number;
|
||||
private _overlayId: number;
|
||||
private _cardBackgroundId: number;
|
||||
|
||||
public flush(): boolean
|
||||
{
|
||||
@@ -21,6 +22,7 @@ export class RoomUnitInfoParser implements IMessageParser
|
||||
this._backgroundId = 0;
|
||||
this._standId = 0;
|
||||
this._overlayId = 0;
|
||||
this._cardBackgroundId = 0;
|
||||
|
||||
return true;
|
||||
}
|
||||
@@ -36,7 +38,9 @@ export class RoomUnitInfoParser implements IMessageParser
|
||||
this._achievementScore = wrapper.readInt();
|
||||
this._backgroundId = wrapper.readInt();
|
||||
this._standId = wrapper.readInt();
|
||||
this._overlayId = wrapper.readInt();
|
||||
this._overlayId = wrapper.readInt();
|
||||
|
||||
if(wrapper.bytesAvailable >= 4) this._cardBackgroundId = wrapper.readInt();
|
||||
|
||||
return true;
|
||||
}
|
||||
@@ -80,4 +84,9 @@ export class RoomUnitInfoParser implements IMessageParser
|
||||
{
|
||||
return this._overlayId;
|
||||
}
|
||||
|
||||
public get cardBackgroundId(): number
|
||||
{
|
||||
return this._cardBackgroundId;
|
||||
}
|
||||
}
|
||||
@@ -37,6 +37,7 @@ export class RoomUnitParser implements IMessageParser
|
||||
const background = wrapper.readInt();
|
||||
const stand = wrapper.readInt();
|
||||
const overlay = wrapper.readInt();
|
||||
const cardBackground = wrapper.readInt();
|
||||
let figure = wrapper.readString();
|
||||
const roomIndex = wrapper.readInt();
|
||||
const x = wrapper.readInt();
|
||||
@@ -53,6 +54,7 @@ export class RoomUnitParser implements IMessageParser
|
||||
user.background = background;
|
||||
user.stand = stand;
|
||||
user.overlay = overlay;
|
||||
user.cardBackground = cardBackground;
|
||||
user.x = x;
|
||||
user.y = y;
|
||||
user.z = z;
|
||||
|
||||
@@ -17,6 +17,7 @@ export class UserMessageData
|
||||
private _background: number = 0;
|
||||
private _stand: number = 0;
|
||||
private _overlay: number = 0;
|
||||
private _cardBackground: number = 0;
|
||||
private _webID: number = 0;
|
||||
private _groupID: number = 0;
|
||||
private _groupStatus: number = 0;
|
||||
@@ -214,6 +215,16 @@ export class UserMessageData
|
||||
this._overlay = k;
|
||||
}
|
||||
|
||||
public get cardBackground(): number
|
||||
{
|
||||
return this._cardBackground;
|
||||
}
|
||||
|
||||
public set cardBackground(k: number)
|
||||
{
|
||||
this._cardBackground = k;
|
||||
}
|
||||
|
||||
public get webID(): number
|
||||
{
|
||||
return this._webID;
|
||||
|
||||
@@ -19,6 +19,7 @@ export class UserProfileParser implements IMessageParser
|
||||
private _backgroundId: number;
|
||||
private _standId: number;
|
||||
private _overlayId: number;
|
||||
private _cardBackgroundId: number;
|
||||
|
||||
public flush(): boolean
|
||||
{
|
||||
@@ -38,6 +39,7 @@ export class UserProfileParser implements IMessageParser
|
||||
this._backgroundId = 0;
|
||||
this._standId = 0;
|
||||
this._overlayId = 0;
|
||||
this._cardBackgroundId = 0;
|
||||
|
||||
return true;
|
||||
}
|
||||
@@ -71,6 +73,8 @@ export class UserProfileParser implements IMessageParser
|
||||
this._backgroundId = wrapper.readInt();
|
||||
this._standId = wrapper.readInt();
|
||||
this._overlayId = wrapper.readInt();
|
||||
|
||||
if(wrapper.bytesAvailable >= 4) this._cardBackgroundId = wrapper.readInt();
|
||||
}
|
||||
|
||||
return true;
|
||||
@@ -155,4 +159,9 @@ export class UserProfileParser implements IMessageParser
|
||||
{
|
||||
return this._overlayId;
|
||||
}
|
||||
|
||||
public get cardBackgroundId(): number
|
||||
{
|
||||
return this._cardBackgroundId;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user