clear_bot_chat - ryzom/ryzomcore GitHub Wiki
title: Clear Bot Chat description: Remove all entries from the NPC botchat menu published: true date: 2026-03-14T00:00:00.000Z tags: editor: markdown dateCreated: 2023-03-16T22:21:35.539Z
The clearBotChat native AI script function removes all entries from the botchat (contextual interaction) menu of every bot in the group. The cleared chat profile is automatically sent to EGS to sync with connected clients.
()clearBotChat()This function takes no arguments.
// Replace an NPC's menu: clear first, then add new entries
()clearBotChat();
()addBotChat("shop:MATIS_ARMOR");
()addBotChat("menu:MENU_WHOAMI WHOAMI_MERCHANT");- Affects all bots in the group.
- Typically called before addBotChat when you want to replace the entire menu rather than append to it.
- If a bot doesn't have a chat profile yet, one is created (empty) automatically.
- addBotChat - Add entries to the botchat menu
Source: ryzom/server/src/ai_service/nf_grp_npc.cpp (clearBotChat__)