feat: take_powerup VFX, rank fix, admin chat management

- Wire take_powerup AnimatedSprite3D on powerup pickup via add_powerup_from_item()
- Make take_powerup animation one-shot (loop: false)
- Fix rank Position label hidden at game start (visible = false, only shows when score > 0)
- Competition ranking for tied scores in main.gd
- Lobby Chat admin tab: system prefix, max messages, wipe, purge old, save config
- Chat Storage admin tab: list/browse/delete individual channel messages
- Backend RPCs: admin_get_chat_config, admin_set_chat_config, admin_purge_old_messages,
  admin_list_channel_messages, admin_delete_channel_message
- Chat config applied on lobby join (max_messages, prefix injection)
This commit is contained in:
2026-06-19 17:13:24 +08:00
parent cd584f5599
commit 15043b5655
12 changed files with 818 additions and 7 deletions
+15
View File
@@ -149,6 +149,21 @@ func _parse_error_msg(msg: String) -> String:
func admin_clear_global_chat(payload: String) -> Dictionary:
return await api_rpc_async("admin_clear_global_chat", payload)
func admin_get_chat_config() -> Dictionary:
return await api_rpc_async("admin_get_chat_config", "{}")
func admin_set_chat_config(config: Dictionary) -> Dictionary:
return await api_rpc_async("admin_set_chat_config", JSON.stringify(config))
func admin_purge_old_messages(channel_id: String, max_age_days: int) -> Dictionary:
return await api_rpc_async("admin_purge_old_messages", JSON.stringify({"channel_id": channel_id, "max_age_days": max_age_days}))
func admin_list_channel_messages(channel_id: String, limit: int = 50, cursor: String = "", forward: bool = true) -> Dictionary:
return await api_rpc_async("admin_list_channel_messages", JSON.stringify({"channel_id": channel_id, "limit": limit, "cursor": cursor, "forward": forward}))
func admin_delete_channel_message(channel_id: String, message_id: String) -> Dictionary:
return await api_rpc_async("admin_delete_channel_message", JSON.stringify({"channel_id": channel_id, "message_id": message_id}))
func send_friend_request(target_id: String) -> Dictionary:
var payload = JSON.stringify({"target_user_id": target_id})
return await api_rpc_async("send_friend_request", payload)