DNF90 服务端与启动器完整源码(含 GM 工具功能增强)
服务端(Go): - GM 塞背包/带属性装备发放:在线角色推送 op14 增量物品行,背包实时刷新,无需回角色选择界面 - GM 改金币/改等级:去掉在线拒绝,落库后推送 op14 钱包/op37 等级状态,在线实时刷新 - 等级端点统一切换到新版 GMSetCharacterLevel(自带在线刷新) - 无限/锁死疲劳模式 + 燃烧疲劳:每房间消耗 2 点、打怪与通关经验双倍 - 燃烧疲劳开关时给所有在线角色推送系统提示(op12 mode 0) - 深渊史诗掉率:GM 全局倍率 + 城镇增益药剂窗口倍率,真实接入掉落结算 启动器(Python/JS): - 标题栏自绘、窗口 1204x717、禁止拖拽改大小、仅最小化/关闭 - GM 工具:疲劳与燃烧、深渊史诗掉率、拍卖行上架(单一定价对齐) - 拍卖行上架前端对齐服务端单一价格语义,修复 400 报错
This commit is contained in:
commit
645b64fe21
4388 files changed
+1405457
No files matched your search
@@ -0,0 +1,78 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"flag"
|
||||
"fmt"
|
||||
"path"
|
||||
"sort"
|
||||
"strings"
|
||||
|
||||
dnfpvf "longheng.io/server/internal/modules/dnf/pvf"
|
||||
platformpvf "longheng.io/server/internal/platform/pvf"
|
||||
)
|
||||
|
||||
type row struct {
|
||||
itemID int64
|
||||
path string
|
||||
name string
|
||||
typ string
|
||||
values []int64
|
||||
}
|
||||
|
||||
func main() {
|
||||
pvfPath := flag.String("pvf", `D:/DNF/runtime/data/dnf/Script.pvf`, "Script.pvf path")
|
||||
flag.Parse()
|
||||
archive, err := platformpvf.Open(*pvfPath)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
listText, err := archive.ReadText("stackable/stackable.lst")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
list, err := dnfpvf.Parse("stackable/stackable.lst", listText)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
rows := make([]row, 0, 256)
|
||||
counts := make(map[string]int)
|
||||
for _, entry := range dnfpvf.ParseList(list) {
|
||||
reference := strings.TrimSpace(strings.Trim(entry.Path, "`\"'"))
|
||||
var actual string
|
||||
for _, candidate := range []string{reference, path.Join("stackable", reference)} {
|
||||
if file, found := archive.FindFile(candidate); found {
|
||||
actual = file.ArchivePath
|
||||
break
|
||||
}
|
||||
}
|
||||
if actual == "" {
|
||||
continue
|
||||
}
|
||||
text, readErr := archive.ReadText(actual)
|
||||
if readErr != nil {
|
||||
continue
|
||||
}
|
||||
document, parseErr := dnfpvf.Parse(actual, text)
|
||||
if parseErr != nil {
|
||||
continue
|
||||
}
|
||||
typ, found := document.Text("increase status type")
|
||||
if !found {
|
||||
continue
|
||||
}
|
||||
typ = strings.ToLower(strings.TrimSpace(strings.ReplaceAll(typ, "`", "")))
|
||||
switch typ {
|
||||
case "[expup]", "[exppercentup]", "[expupbytable]", "[levelupbytable]":
|
||||
default:
|
||||
continue
|
||||
}
|
||||
name, _ := document.Text("name")
|
||||
rows = append(rows, row{itemID: entry.ID, path: actual, name: name, typ: typ, values: document.Ints("increase status type")})
|
||||
counts[typ]++
|
||||
}
|
||||
sort.Slice(rows, func(i, j int) bool { return rows[i].itemID < rows[j].itemID })
|
||||
for _, item := range rows {
|
||||
fmt.Printf("%d\t%s\t%v\t%s\t%s\n", item.itemID, item.typ, item.values, item.name, item.path)
|
||||
}
|
||||
fmt.Printf("TOTAL=%d COUNTS=%v\n", len(rows), counts)
|
||||
}
|
||||
Reference in new issue
Block a user