[DiscordArchive] Hello everyone, I have a question that has been bothering me for a long time: how does the class tra
[DiscordArchive] Hello everyone, I have a question that has been bothering me for a long time: how does the class tra
Archived author: may • Posted: 2022-06-22T11:03:29.735000+00:00
Original source
Hello everyone, I have a question that has been bothering me for a long time: how does the class trainer judge the player's class and decide whether to teach it or not?
If I want a mage to learn paladin spells from a paladin trainer, what do I need to modify?
Archived author: <o> • Posted: 2022-06-22T11:07:48.443000+00:00
Original source
the `trainer` table has a `Type` and a `Requirement` field. If `Type` is 0, then `Requirement` is the class that it will teach spells to. On unmodified trinitycore, this means a class trainer can only teach spells to one class or all classes
Archived author: <o> • Posted: 2022-06-22T11:08:55.838000+00:00
Original source
this is usually not enough to allow your class to learn the spells. I don't remember the exact rules, but i do believe trainers also need you to set up the `SkillRaceClassInfos.dbc` for the skill and the `SkillLineAbility` for the spells
![[Image: unknown.png?ex=690c82b4&is=690b3134&hm=a...e9a23491c&]](https://cdn.discordapp.com/attachments/415944535718494208/989125820473823262/unknown.png?ex=690c82b4&is=690b3134&hm=adcb08c7d6b36b1451b4b78e6592f3505e7bfd22b0b7a4410b11db5e9a23491c&)
Archived author: may • Posted: 2022-06-22T11:12:52.811000+00:00
Original source
I did modify the trainer table for a certain trainer, but it doesn't seem to work.
![[Image: unknown.png?ex=690c82b4&is=690b3134&hm=a...e9a23491c&]](https://cdn.discordapp.com/attachments/415944535718494208/989125820473823262/unknown.png?ex=690c82b4&is=690b3134&hm=adcb08c7d6b36b1451b4b78e6592f3505e7bfd22b0b7a4410b11db5e9a23491c&)
Archived author: may • Posted: 2022-06-22T11:14:51.448000+00:00
Original source
He doesn't think my mage character is a paladin and refuses to teach me
Archived author: <o> • Posted: 2022-06-22T11:17:06.395000+00:00
Original source
there are usually conditions applied to the gossips as well
Archived author: <o> • Posted: 2022-06-22T11:17:59.490000+00:00
Original source
<https://trinitycore.atlassian.net/wiki/spaces/tc/pages/187727908/gossip_menu_option>
<https://trinitycore.atlassian.net/wiki/spaces/tc/pages/2130002/conditions>
Archived author: <o> • Posted: 2022-06-22T11:18:26.395000+00:00
Original source
it's a little complicated but if it's a trainer from blizzard they usually have these
Archived author: <o> • Posted: 2022-06-22T11:18:43.814000+00:00
Original source
not sure why, since the trainer type already filters it
Archived author: may • Posted: 2022-06-22T11:24:15.760000+00:00
Original source
I found some clues in core but I didn't test it because I know it's better not to touch core cpp if it can be solved from db or dbc