Commit Graph
7 Commits
Author SHA1 Message Date
Karrz1 89a0da4ea0 Bots: "accept" also takes quests that start from an item in the bags
A bot that loots a quest starting item (a letter, a head, a wanted note)
already took that quest by itself after a few seconds. Now the owner's
"accept" (and the AI bots bridge's accept) takes it at once as well, from
the item, the way a player right-clicks it, and says so. A refusal gets
its reason like any other accept. The snapshot keeps the item's guid so
the accept can name the item as the quest giver.

Quest objects (wanted boards, chests that give quests) were already in
the bot's offers and need nothing new.
2026-11-12 09:21:29 +00:00
Karrz1 6d00bb73ca Bots: say why a quest could not be taken
When a player tells a bot to take a quest ("accept", the AI bots bridge,
or a quest shared with the group) and the server refuses it, the bot
used to go quiet. Now it whispers the reason: level too low or too high,
not for its class or race, the quest before it not done, already done
or in the log, another quest rules it out, daily not reset yet, quest
log full, no bag room for the quest item, giver gone or too far, turned
off on this server. A named quest that nobody near offers gets the same
reason when the bot could not take it anyway.

The reason is the first of the server's own accept gates that fails,
checked without a message to the bot's client. The bot's own questing
stays quiet. Russian lines included.
2026-11-12 09:21:22 +00:00
Karrz1 964a8bf8b6 Bots: the world chatter, channel and guild lines in the reader's language
A Russian client read the bots' replies to it in Russian, but everything the bots say among themselves arrived in English
(Discord, fox: "in the group they answer in Russian, between themselves they speak English"). Two causes:

- The stock chatter lines (playerbot_v2_bot_text, migration 0019: suggest_*, taunts, loot and kill lines, replies, emote
  answers) had no Russian at all. RussianChatterEntries now carries a Russian line for each one the bots speak, written with
  the database's own placeholders; Catalog::AddChatter turns them into templates. Placeholders filled with a chat link, a
  number, money or a name become narrow captures, so a short line ("got %item_link", "hey %s") never takes an unrelated line
  that only starts the same way. The LFG calls and whispers (ChannelTalk) and the guild small talk (GuildRules) are added to
  the code catalog, with the faction and reputation words the chatter names.
- Channel lines (General, Trade, LookingForGroup) went out through Channel::Say and guild lines through
  Guild::BroadcastToGuild, one text for every member. Both gain an overload that takes the text per member, with the same
  checks and one packet per distinct text; BotLanguage::ChannelSay / GuildSay give each member the line in their language.

Item, zone, instance and creature names stay as the server has them. Unit tests: every chatter line keeps its placeholders,
sample lines, and short lines that must stay English. `.playerbot langprobe <line>` shows the Russian a running build gives.

(cherry picked from commit 27d6ec820804089f399802e98e155ed9fe76c72f)
2026-11-12 00:47:01 +00:00
Karrz1 8d2d35a955 Raid: a raid leader bot who reacts to mistakes, and wipe banter
In a raid or party with a real player, one bot leads the chat (the group
leader if that is a bot, else an assistant bot, else the first bot) and
reacts the way a real raid leader does:

- standing in fire or another bad area ("Karrz GET OUT OF IT"),
- a cast nobody kicked ("NOBODY KICKED Shadow Bolt??"),
- a broken crowd control, named when the server saw who hit it,
- an extra pull ("WHO PULLED THAT. adds on Brok").

After a wipe one or two other bots answer: blame, excuses, "my bad" (the
one who died first speaks for himself). The kill gets a "gg".

Playerbot.Raid.Banter: 0 off, 1 mild (teasing, the default), 2 harsh (a
leader who freaks out at every mishap). Game mistakes only, in good fun:
never about the person, never a slur. Rate limited per raid: one line every
20 s (10 s on harsh), the same mistake once in 45 s, the same raider once
in 90 s. In a party of 15 or fewer with PartyBanter on, the wipe and kill
lines stay the companions' own.

No model needed: every line has a fixed form, mild and harsh, with Russian
for Russian clients. With the bot bridge answering chat, a new raid_line
event asks the program for the line in the bot's own words; an answer not
back within 2.5 s is dropped and the fixed line is said, so the raid never
waits. The example program answers it with the main model only, a short
prompt and a few tokens, and its filter still removes slurs whatever the
realm's swearing setting.

(cherry picked from commit d7681e0a2d91d5186d6849804be2a31b874330b8)
2026-11-11 23:44:07 +00:00
Karrz1 a7feec8180 Raid: the player's boss tactics in plain words, kept per boss
"tactics Lucifron: adds first, no aoe, no fear, tank here" in party, raid,
a whisper or a ';' line. The plan is kept for that boss (per account, across
restarts) and the bots follow it every time the boss is in the fight:

- adds first: the damage dealers leave the boss to the tanks while one of his
  adds is up; boss first: they stay on him and the tanks keep the adds.
- no aoe: no spell that hits more than one enemy in that fight.
- no fear / no sheep / no banish ...: that crowd control is not elected and not
  cast in that fight, on top of the owner's standing orders.
- tank here: the tank holding the boss drags him to where the player stood,
  never into a hazard and not where the raid rules already place the tank.

"tactics: boss first" uses the targeted boss, "tactics Lucifron" shows his plan,
"tactics" lists all, "clear" drops one. Names can be short ("geddon") and a plan
can be set from outside the raid. No model is needed; with the bot bridge on, a
free sentence becomes the same order ("tactics ..." is one of its safe orders).
Plain party chat that only starts with the word stays chatter. Russian clients
get the answers in Russian.

New table playerbot_v2_owner_tactics (migration 0039).

(cherry picked from commit 99f77b0b0e04ec83c2b0da6f13c5f274523c7245)
2026-11-11 23:44:07 +00:00
Karrz1 a5216cd0f1 Raid: bots call out what they do in raid chat, like players
"Living Bomb on me, running out", "taunting Flamegor", "Polymorph on
Flamewaker Healer, don't break it", "spread out", "wipe, run back to the
entrance". The line comes from the raid brain's own decision at the moment it
changes, so no model is needed and it works on every setup.

Rate limited so raid chat reads like players: one line per bot every 6 s,
the same line from one bot every 20 s, a raid-wide call (spread, wipe, dance)
once per 45 s, and at most 5 lines in 20 s for the whole raid. Only groups
with a real player hear them. Russian readers get the lines from the catalog.

Playerbot.Raid.Callouts = 0 turns them off (default 1).

(cherry picked from commit 0dd07cdb2197ec7fa04b407988f99751dce99ca7)
2026-11-11 23:44:07 +00:00
Karrz1 b5f1d43560 Merge forever (sync with WoW Forever 0.1.34) into forever-bots
forever-bots is forever plus the optional player bots module (src/modules/PlayerbotV2), now at our 0.1.34 bot code:
dungeon and raid tactics (BWL Nefarian, Zul'Gurub), pull back, ships and zeppelins, gear trading, orders in party chat,
autosave every 15 minutes, the ForeverBots add-on 0.6.20 and the Playerbot.Enable master switch.
World PvP bots and the optional bot chat program are in the module but off by default.
2026-11-09 17:27:57 +00:00