เริ่มจาก Config / Server Console#
หลัง ensure nX_police ให้แก้ Config error ที่ validator ระบุก่อนตรวจ gameplay symptom
หา Config ไม่เจอหลังอัปเดต#
รุ่นใหม่ไม่มี config/shared แล้ว ใช้ config/customer, config/data และ config/locales และดูหน้า Config Migration
Recovery commands#
| Command | ใช้เมื่อ |
|---|---|
policepanel | เปิด Police Command โดยยังใช้สิทธิ์ตามระบบตามปกติ |
policeuifix | ใช้เมื่อ UI ค้างหรือการรับเมาส์/คีย์บอร์ดผิดปกติ |
Local diagnostics#
ใช้คำสั่งเหล่านี้ใน F8 เพื่อเก็บข้อมูลประกอบการตรวจปัญหา:
nxpolice_doctor- read-only smoke test ตรวจ Runtime, DB schema, dependencies, NC hook, locale, cache และ production hygiene พร้อม PASS/WARN/FAILkssquaddiag- local Squad diagnostic; command จะถูก register เฉพาะเมื่อConfig.General.Debug=truekssirencheck- local Siren/Squad visual diagnostic; register เฉพาะ Debug mode
ติดต่อ Support#
หากต้องติดต่อ Support ให้รัน nxpolice_doctor แล้วส่งเฉพาะผล PASS/WARN/FAIL และ log ที่เกี่ยวข้อง โดยลบหรือปิดบัง IP, webhook, token, password, API key, connection string และ player identifier ก่อนส่ง ห้ามส่ง server.cfg, database dump หรือไฟล์ secret
Maintenance#
policebootstrap <server id> เป็น setup/recovery command ไม่ใช่ gameplay command: Console ใช้ได้ ผู้เล่นต้องผ่าน configuration group หรือ ACE nX_police.bootstrap
Statistics reset ใช้ /nxresetstatistics แล้ว /nxresetstatistics confirm เท่านั้น
POLICE+#
/police+ ใช้ AdminGroups/Config.Jail.Editor ตาม policy และใช้สำหรับ Jail Area Editor เท่านั้น ดูหน้า POLICE+ Admin Tools สำหรับขั้นตอนสร้าง/แก้พื้นที่คุก
ค้นตัวหรือยึดของไม่ตรง#
- ตรวจ
Config.Integrations.Inventory.Resource - แก้ signature ที่
config/functionsตาม API ของ Inventory - ต้อง Remove สำเร็จก่อน RecordSeizedEvidence/Deposit flow
ถูกล็อคมือแล้วยังเปิด UI / กดปุ่มที่ไม่ควรได้#
- ตรวจ
Config.Cuff.Whitelist: Control ID ต้องใส่เป็นตัวเลข ส่วน mapped key เช่น F6/T/ALT+K ต้องใส่เป็น string ในรายการเดียวกัน - ตรวจว่าปุ่มที่ resource ใช้เปิด UI ตรงกับค่าที่ใส่ใน Whitelist จริง เช่น nc_inventory แบบ keybinding ใช้ค่าปุ่ม open ของ NC
- ตรวจว่ามีปุ่มเกินจากที่ต้องการหรือมีค่าซ้ำหรือไม่
- UI ภายนอกต้องส่งปุ่ม/Control ID เข้า
CanOpenUiหรือSetCuffUiActiveตอนเปิด และเรียกSetCuffUiActive(name, false)ตอนปิด - หลังแก้ Config ให้ restart
nX_policeแล้วทดสอบใหม่
Item ปลดกุญแจมือ / GPS Cutter ไม่ทำงาน#
- ตรวจ
Config.Cuff.UnlockItem.EnabledหรือConfig.Jail.Escape.GpsCutter.Enabled - ตรวจชื่อ item ให้ตรงกับ Inventory จริง
- Unlock Item และ GPS Cutter ห้ามใช้ชื่อ item เดียวกัน
- ถ้า
ConsumeOnUse=falseระบบยังต้องอ่าน item count ได้; ตรวจ Inventory bridge/Adapter - ถ้า
RequireForPoliceUncuff=trueต้องเปิด UnlockItem.Enabled ด้วย - ดู Config Validator ใน Server Console หลัง restart
หากใช้ระบบตาย/ชุบแบบ Custom ให้ทดสอบ AutoUncuffOnDeath หลังเชื่อมระบบนั้น หากไม่ปลดตาม Config ให้แนบ F8/Server Console ติดต่อ Support
External Notify ไม่ขึ้น / ขึ้นซ้ำ#
- ตรวจ
Provider='external' - ตรวจ resource started
- ตรวจ
Functions.Client.ExternalNotify - Adapter ต้อง
return trueเมื่อแสดงสำเร็จ - เปิด
FallbackToInternal=trueระหว่างทดสอบ
ถ้าขึ้นซ้ำ อย่าให้ Adapter เรียก Internal toast เองอีกครั้ง
ตายแล้วเปิด UI ไม่ได้ / ยังเปิดได้#
- ตรวจ
Config.UI.AllowWhileDeadในconfig/customer/07_ui.lua true= อนุญาตเปิด UI ตอนตายfalse= บล็อกการเปิดและปิด UI ของ nX Police ที่เปิดค้างเมื่อผู้เล่นตาย- UI ภายนอกต้องเชื่อม
CanOpenUi/SetCuffUiActiveจึงจะใช้ policy เดียวกัน
UI เปิดไม่ได้ / UI ค้าง#
- ตรวจไฟล์
web/distและlegacyอยู่ครบ - ดู F8 + Server Console พร้อมกัน
- ลอง
policeuifixหากเป็น focus state ค้าง
Resource ไม่ผ่าน License#
- ตรวจ Public Server IP ตรงกับ License
- ย้าย VPS/ISP ให้แก้ IP ก่อน
- ใช้ Package เดิมและแก้เฉพาะไฟล์ที่คู่มืออนุญาต