付费配置 界面

This commit is contained in:
zcl
2025-08-13 17:10:12 +08:00
parent ef02eedac6
commit 62347f08e9
20 changed files with 24189 additions and 754 deletions
Binary file not shown.
Binary file not shown.
Binary file not shown.
+2 -1
View File
@@ -4,6 +4,7 @@
"Model": "gemini-2.5-flash",
"Temperature": 0.7,
"MaxTokens": 2048,
"Timeout": 30000
"Timeout": 30000,
"FreeChatTimes": 20
}
]
+44
View File
@@ -0,0 +1,44 @@
[
{
"id": 1001,
"name": "钻石1",
"desc": "1000",
"count": 1001001
},
{
"id": 1002,
"name": "钻石2",
"desc": "3000",
"count": 1001002
},
{
"id": 1003,
"name": "钻石3",
"desc": "5000",
"count": 1001003
},
{
"id": 1004,
"name": "钻石4",
"desc": "10000",
"count": 1001004
},
{
"id": 1005,
"name": "钻石5",
"desc": "20000",
"count": 1001005
},
{
"id": 1006,
"name": "钻石6",
"desc": "30000",
"count": 1001006
},
{
"id": 2001,
"name": "特权卡",
"desc": "168",
"count": 1002001
}
]
+86
View File
@@ -193,6 +193,7 @@ export class GlobalConfig {
this.Temperature = _buf_.readFloat()
this.MaxTokens = _buf_.readInt()
this.Timeout = _buf_.readInt()
this.FreeChatTimes = _buf_.readInt()
}
/**
@@ -212,6 +213,10 @@ export class GlobalConfig {
* 超时时间(微秒)
*/
readonly Timeout: number
/**
* 单个角色免费聊天次数
*/
readonly FreeChatTimes: number
resolve(tables:Tables) {
@@ -219,6 +224,7 @@ export class GlobalConfig {
}
}
@@ -270,6 +276,44 @@ export class Language {
export class PurchaseConfig {
constructor(_buf_: ByteBuf) {
this.id = _buf_.readInt()
this.name = _buf_.readString()
this.desc = _buf_.readString()
this.count = _buf_.readInt()
}
/**
* 商品id
*/
readonly id: number
/**
* 名称
*/
readonly name: string
/**
* 数量
*/
readonly desc: string
/**
* 计费点ID
*/
readonly count: number
resolve(tables:Tables) {
}
}
export class Theme {
constructor(_buf_: ByteBuf) {
@@ -582,6 +626,10 @@ export class TbGlobalConfig {
* 超时时间(微秒)
*/
get Timeout(): number { return this._data.Timeout; }
/**
* 单个角色免费聊天次数
*/
get FreeChatTimes(): number { return this._data.FreeChatTimes; }
resolve(tables:Tables) {
this._data.resolve(tables)
@@ -592,6 +640,39 @@ export class TbGlobalConfig {
export class TbPurchaseConfig {
private _dataMap: Map<number, PurchaseConfig>
private _dataList: PurchaseConfig[]
constructor(_buf_: ByteBuf) {
this._dataMap = new Map<number, PurchaseConfig>()
this._dataList = []
for(let n = _buf_.readInt(); n > 0; n--) {
let _v: PurchaseConfig
_v = new PurchaseConfig(_buf_)
this._dataList.push(_v)
this._dataMap.set(_v.id, _v)
}
}
getDataMap(): Map<number, PurchaseConfig> { return this._dataMap; }
getDataList(): PurchaseConfig[] { return this._dataList; }
get(key: number): PurchaseConfig | undefined {
return this._dataMap.get(key);
}
resolve(tables:Tables) {
for(let data of this._dataList)
{
data.resolve(tables)
}
}
}
type ByteBufLoader = (file: string) => ByteBuf
export class Tables {
@@ -607,6 +688,8 @@ export class Tables {
get TbAiCharacters(): TbAiCharacters { return this._TbAiCharacters;}
private _TbGlobalConfig: TbGlobalConfig
get TbGlobalConfig(): TbGlobalConfig { return this._TbGlobalConfig;}
private _TbPurchaseConfig: TbPurchaseConfig
get TbPurchaseConfig(): TbPurchaseConfig { return this._TbPurchaseConfig;}
static getTableNames(): string[] {
let names: string[] = [];
@@ -616,6 +699,7 @@ export class Tables {
names.push('tbthemes');
names.push('tbaicharacters');
names.push('tbglobalconfig');
names.push('tbpurchaseconfig');
return names;
}
@@ -626,6 +710,7 @@ export class Tables {
this._TbThemes = new TbThemes(loader('tbthemes'))
this._TbAiCharacters = new TbAiCharacters(loader('tbaicharacters'))
this._TbGlobalConfig = new TbGlobalConfig(loader('tbglobalconfig'))
this._TbPurchaseConfig = new TbPurchaseConfig(loader('tbpurchaseconfig'))
this._TbLanguage.resolve(this)
this._TbGirls.resolve(this)
@@ -633,6 +718,7 @@ export class Tables {
this._TbThemes.resolve(this)
this._TbAiCharacters.resolve(this)
this._TbGlobalConfig.resolve(this)
this._TbPurchaseConfig.resolve(this)
}
}
File diff suppressed because it is too large Load Diff
+1 -1
View File
@@ -2,7 +2,7 @@
"ver": "1.1.50",
"importer": "prefab",
"imported": true,
"uuid": "4879d105-bcc4-4865-909e-3557b8a5e094",
"uuid": "42ea4b21-1bc4-42c9-988f-fb5cc272c39f",
"files": [
".json"
],
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,13 @@
{
"ver": "1.1.50",
"importer": "prefab",
"imported": true,
"uuid": "4879d105-bcc4-4865-909e-3557b8a5e094",
"files": [
".json"
],
"subMetas": {},
"userData": {
"syncNodeName": "ChatPanel1"
}
}
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,13 @@
{
"ver": "1.1.50",
"importer": "prefab",
"imported": true,
"uuid": "20f8c223-400b-4d21-9e93-351fb81dfd59",
"files": [
".json"
],
"subMetas": {},
"userData": {
"syncNodeName": "PurchasePanel"
}
}
File diff suppressed because it is too large Load Diff
Binary file not shown.
@@ -0,0 +1 @@
ƒιι’»η³11000ΟF)ƒκι’»η³23000ΟF*ƒλι’»η³35000ΟF+ƒμι’»η³410000ΟF,ƒνι’»η³520000ΟF-ƒξι’»η³630000ΟF.‡Ρ η‰Ήζƒε΅168ΟJ
@@ -0,0 +1,12 @@
{
"ver": "1.0.3",
"importer": "buffer",
"imported": true,
"uuid": "9cb9b546-ed4f-43d5-9b00-b153f0f59bd6",
"files": [
".bin",
".json"
],
"subMetas": {},
"userData": {}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "a2283a24-1b1c-4dc3-bf6e-8116cf91173f",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "a2283a24-1b1c-4dc3-bf6e-8116cf91173f@6c48a",
"displayName": "Task_icon_task",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "a2283a24-1b1c-4dc3-bf6e-8116cf91173f",
"isUuid": true,
"visible": false,
"minfilter": "linear",
"magfilter": "linear",
"mipfilter": "none",
"anisotropy": 0
},
"ver": "1.0.22",
"imported": true,
"files": [
".json"
],
"subMetas": {}
},
"f9941": {
"importer": "sprite-frame",
"uuid": "a2283a24-1b1c-4dc3-bf6e-8116cf91173f@f9941",
"displayName": "Task_icon_task",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 96,
"height": 97,
"rawWidth": 96,
"rawHeight": 97,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-48,
-48.5,
0,
48,
-48.5,
0,
-48,
48.5,
0,
48,
48.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
97,
96,
97,
0,
0,
96,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-48,
-48.5,
0
],
"maxPos": [
48,
48.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "a2283a24-1b1c-4dc3-bf6e-8116cf91173f@6c48a",
"atlasUuid": ""
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"hasAlpha": true,
"fixAlphaTransparencyArtifacts": false,
"redirect": "a2283a24-1b1c-4dc3-bf6e-8116cf91173f@6c48a"
}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

@@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "61e97dad-9d64-4748-9eab-8af0776fb79d",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "61e97dad-9d64-4748-9eab-8af0776fb79d@6c48a",
"displayName": "common_close_3",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "61e97dad-9d64-4748-9eab-8af0776fb79d",
"isUuid": true,
"visible": false,
"minfilter": "linear",
"magfilter": "linear",
"mipfilter": "none",
"anisotropy": 0
},
"ver": "1.0.22",
"imported": true,
"files": [
".json"
],
"subMetas": {}
},
"f9941": {
"importer": "sprite-frame",
"uuid": "61e97dad-9d64-4748-9eab-8af0776fb79d@f9941",
"displayName": "common_close_3",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 80,
"height": 85,
"rawWidth": 80,
"rawHeight": 85,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-40,
-42.5,
0,
40,
-42.5,
0,
-40,
42.5,
0,
40,
42.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
85,
80,
85,
0,
0,
80,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-40,
-42.5,
0
],
"maxPos": [
40,
42.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "61e97dad-9d64-4748-9eab-8af0776fb79d@6c48a",
"atlasUuid": ""
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"hasAlpha": true,
"fixAlphaTransparencyArtifacts": false,
"redirect": "61e97dad-9d64-4748-9eab-8af0776fb79d@6c48a"
}
}