[DiscordArchive] Hello. Using AzerothCore, I'm trying to rework ...
[DiscordArchive] Hello. Using AzerothCore, I'm trying to rework ...
Archived author: Needle • Posted: 2025-04-27T14:02:50.289000+00:00
Original source
Archived author: Needle • Posted: 2025-04-27T14:02:50.868000+00:00
Original source
Thread automatically created by ravador in <#415944535718494208>
Archived author: ravador • Posted: 2025-04-27T14:02:56.163000+00:00
Original source
I have created 2 new spells in spell editor, copying 27243 and 27285 and rewriting them slightly to fit what I want them to do. I learned the new spells in game with gm commands and I tested them both. The spell copied from 27285 (the explosion part of Seed of Corruption) works on its own at applying Corruption correctly. The problem is that the first part of the new Seed of Corruption still does the AoE explosion. I looked into the src/server/scripts/Spells/spell_warlock.cpp, rewrote the SPELL_WARLOCK_SEED_OF_CORRUPTION_DAMAGE_R1 enum to my new spell ID, uploaded it onto the server, recompiled and restarted, thinking that it would fix it, however, it still does the explosion.
Archived author: ravador • Posted: 2025-04-27T14:03:34.845000+00:00
Original source
I also updated the spell_script_names and spell_ranks of teh new spells
Archived author: ravador • Posted: 2025-04-27T14:03:42.821000+00:00
Original source
```
DELETE FROM `spell_ranks` WHERE (`first_spell_id` = 100200 AND `rank` = 1);
DELETE FROM `spell_ranks` WHERE (`first_spell_id` = 100201 AND `rank` = 1);
INSERT INTO `spell_ranks` VALUES
(100200,100200,1),
(100201,100201,1);
DELETE FROM `spell_script_names` WHERE (`spell_id` = -100200);
DELETE FROM `spell_script_names` WHERE (`spell_id` = -100201);
INSERT INTO `spell_script_names` VALUES
(-100201,'spell_warl_seed_of_corruption_damage'),
(-100200,'spell_warl_seed_of_corruption_aura');
```
Archived author: ravador • Posted: 2025-04-27T14:04:36.694000+00:00
Original source
I am basically 100% sure that the problem is in the script, but I don't know how to fix it.
Archived author: ravador • Posted: 2025-04-27T14:06:34.792000+00:00
Original source
I also tried creating a custom script and hooking it up through the custom_script_loader, however, that completely broke the explosion trigger, so it's safe to say that the script wasn't working
Archived author: ravador • Posted: 2025-04-27T14:08:04.554000+00:00
Original source
the thing I'm not understanding in the src/server/scripts/Spells/spell_warlock.cpp is line 741
I feel like this is where it should cast the explosion part of the spell on the target, however, I do not understand how it chooses what spell to cast
Archived author: ravador • Posted: 2025-04-27T14:08:13.432000+00:00
Original source
```
GetCaster()->CastSpell(GetTarget(), sSpellMgr->GetSpellWithRank(SPELL_WARLOCK_SEED_OF_CORRUPTION_DAMAGE_R1, GetSpellInfo()->GetRank()), true, nullptr, aurEff);
```
Archived author: ravador • Posted: 2025-04-27T14:09:12.553000+00:00
Original source
I suspected that it just gets the rank of the explosion spell, which is the same as the rank of the cast spell (Rank 1 in this case), but then why did changing the SPELL_WARLOCK_SEED_OF_CORRUPTION_DAMAGE_R1 enum from 27285 to 100201 didn't do anything?