Forums WoW Modding Support Archives TrinityCore Discord Archives [DiscordArchive] I don't think vehicles are effected by knockback abilities by default right?

[DiscordArchive] I don't think vehicles are effected by knockback abilities by default right?

[DiscordArchive] I don't think vehicles are effected by knockback abilities by default right?

Pages (2): 1 2 Next
rektbyfaith
Administrator
0
07-30-2025, 11:54 AM
#1
Archived author: stoneharry • Posted: 2025-07-30T11:54:27.498000+00:00
Original source

I don't think vehicles are effected by knockback abilities by default right?
rektbyfaith
07-30-2025, 11:54 AM #1

Archived author: stoneharry • Posted: 2025-07-30T11:54:27.498000+00:00
Original source

I don't think vehicles are effected by knockback abilities by default right?

rektbyfaith
Administrator
0
07-30-2025, 11:58 AM
#2
Archived author: Crane • Posted: 2025-07-30T11:58:34.189000+00:00
Original source

The problem with this game is that it's also used by other NPCs and works even when the NPC isn't in a vehicle, but it's also used for the quest "Into the Pit."

Here, the player has an action bar with exactly this spell, and it's supposed to trigger the knockback: https://www.youtube.com/watch?v=BIKdu9PS4p0
[Embed: Into the Pit Quest Playthrough - Storm Peaks]
World Of Warcraft Quest Guide
Into the Pit Quest Playthrough - Storm Peaks


This video is made by
World of warcraft Guides and Gameplay
Hope you enjoy remember to like and subscribe Buy World of Warcraft Legion
https://www.g2a.com/r/worldofwwarcaftlegion
Buy Cheap Game time
EU
https://www.g2a.com/r/wowprepaidcard60
US
https://www.g2a.com/...
https://www.youtube.com/watch?v=BIKdu9PS4p0
rektbyfaith
07-30-2025, 11:58 AM #2

Archived author: Crane • Posted: 2025-07-30T11:58:34.189000+00:00
Original source

The problem with this game is that it's also used by other NPCs and works even when the NPC isn't in a vehicle, but it's also used for the quest "Into the Pit."

Here, the player has an action bar with exactly this spell, and it's supposed to trigger the knockback: https://www.youtube.com/watch?v=BIKdu9PS4p0
[Embed: Into the Pit Quest Playthrough - Storm Peaks]
World Of Warcraft Quest Guide
Into the Pit Quest Playthrough - Storm Peaks


This video is made by
World of warcraft Guides and Gameplay
Hope you enjoy remember to like and subscribe Buy World of Warcraft Legion
https://www.g2a.com/r/worldofwwarcaftlegion
Buy Cheap Game time
EU
https://www.g2a.com/r/wowprepaidcard60
US
https://www.g2a.com/...
https://www.youtube.com/watch?v=BIKdu9PS4p0

rektbyfaith
Administrator
0
07-30-2025, 12:02 PM
#3
Archived author: stoneharry • Posted: 2025-07-30T12:02:17.161000+00:00
Original source

It probably needs a custom attribute or spell script to allow the knockback to effect vehicles. I'm on my phone so can't check the source code.

If you wanted to debug it, check spelleffects.cpp. This defines the Impl for each effect type. If you check knockback, you should be able to follow it through and see where it validates targets
rektbyfaith
07-30-2025, 12:02 PM #3

Archived author: stoneharry • Posted: 2025-07-30T12:02:17.161000+00:00
Original source

It probably needs a custom attribute or spell script to allow the knockback to effect vehicles. I'm on my phone so can't check the source code.

If you wanted to debug it, check spelleffects.cpp. This defines the Impl for each effect type. If you check knockback, you should be able to follow it through and see where it validates targets

rektbyfaith
Administrator
0
07-30-2025, 12:03 PM
#4
Archived author: Crane • Posted: 2025-07-30T12:03:36.881000+00:00
Original source

I've already tried it with a spell script in different variations, and I've also patched the dbc directly and changed the spell without success.
rektbyfaith
07-30-2025, 12:03 PM #4

Archived author: Crane • Posted: 2025-07-30T12:03:36.881000+00:00
Original source

I've already tried it with a spell script in different variations, and I've also patched the dbc directly and changed the spell without success.

rektbyfaith
Administrator
0
07-30-2025, 12:04 PM
#5
Archived author: stoneharry • Posted: 2025-07-30T12:04:23.344000+00:00
Original source

Try looking at the source code I mentioned
rektbyfaith
07-30-2025, 12:04 PM #5

Archived author: stoneharry • Posted: 2025-07-30T12:04:23.344000+00:00
Original source

Try looking at the source code I mentioned

rektbyfaith
Administrator
0
07-30-2025, 12:07 PM
#6
Archived author: Crane • Posted: 2025-07-30T12:07:59.440000+00:00
Original source

``` &Spell::EffectKnockBack, // 98 SPELL_EFFECT_KNOCK_BACK ```

```void Spell::EffectKnockBack()
{
if (effectHandleMode != SPELL_EFFECT_HANDLE_HIT_TARGET)
return;

if (!unitTarget)
return;

if (m_caster->GetAffectingPlayer())
if (Creature* creatureTarget = unitTarget->ToCreature())
if (creatureTarget->isWorldBoss() || creatureTarget->IsDungeonBoss())
return;

// Spells with SPELL_EFFECT_KNOCK_BACK (like Thunderstorm) can't knockback target if target has ROOT
if (unitTarget->HasUnitState(UNIT_STATE_ROOT))
return;

float ratio = 0.1f;
float speedxy = float(effectInfo->MiscValue) * ratio;
float speedz = float(damage) * ratio;
if (speedxy < 0.01f && speedz < 0.01f)
return;

float x, y;
if (effectInfo->Effect == SPELL_EFFECT_KNOCK_BACK_DEST)
{
if (m_targets.HasDst())
destTarget->GetPosition(x, y);
else
return;
}
else //if (m_spellInfo->Effects[i].Effect == SPELL_EFFECT_KNOCK_BACK)
m_caster->GetPosition(x, y);

unitTarget->KnockbackFrom(x, y, speedxy, speedz);
}```
I can't find anything more about the effect
rektbyfaith
07-30-2025, 12:07 PM #6

Archived author: Crane • Posted: 2025-07-30T12:07:59.440000+00:00
Original source

``` &Spell::EffectKnockBack, // 98 SPELL_EFFECT_KNOCK_BACK ```

```void Spell::EffectKnockBack()
{
if (effectHandleMode != SPELL_EFFECT_HANDLE_HIT_TARGET)
return;

if (!unitTarget)
return;

if (m_caster->GetAffectingPlayer())
if (Creature* creatureTarget = unitTarget->ToCreature())
if (creatureTarget->isWorldBoss() || creatureTarget->IsDungeonBoss())
return;

// Spells with SPELL_EFFECT_KNOCK_BACK (like Thunderstorm) can't knockback target if target has ROOT
if (unitTarget->HasUnitState(UNIT_STATE_ROOT))
return;

float ratio = 0.1f;
float speedxy = float(effectInfo->MiscValue) * ratio;
float speedz = float(damage) * ratio;
if (speedxy < 0.01f && speedz < 0.01f)
return;

float x, y;
if (effectInfo->Effect == SPELL_EFFECT_KNOCK_BACK_DEST)
{
if (m_targets.HasDst())
destTarget->GetPosition(x, y);
else
return;
}
else //if (m_spellInfo->Effects[i].Effect == SPELL_EFFECT_KNOCK_BACK)
m_caster->GetPosition(x, y);

unitTarget->KnockbackFrom(x, y, speedxy, speedz);
}```
I can't find anything more about the effect

rektbyfaith
Administrator
0
07-30-2025, 12:09 PM
#7
Archived author: Crane • Posted: 2025-07-30T12:09:53.431000+00:00
Original source

And in EFFECT_0 it has TARGET_UNIT_TARGET_ENEMY
rektbyfaith
07-30-2025, 12:09 PM #7

Archived author: Crane • Posted: 2025-07-30T12:09:53.431000+00:00
Original source

And in EFFECT_0 it has TARGET_UNIT_TARGET_ENEMY

rektbyfaith
Administrator
0
07-30-2025, 12:10 PM
#8
Archived author: stoneharry • Posted: 2025-07-30T12:10:52.254000+00:00
Original source

Is it a world boss or dungeon boss? I doubt it

Does the vehicle have unit state root? Maybe, check npc info command output
rektbyfaith
07-30-2025, 12:10 PM #8

Archived author: stoneharry • Posted: 2025-07-30T12:10:52.254000+00:00
Original source

Is it a world boss or dungeon boss? I doubt it

Does the vehicle have unit state root? Maybe, check npc info command output

rektbyfaith
Administrator
0
07-30-2025, 12:11 PM
#9
Archived author: stoneharry • Posted: 2025-07-30T12:11:19.848000+00:00
Original source

You might also need to check inside knockback from impl
rektbyfaith
07-30-2025, 12:11 PM #9

Archived author: stoneharry • Posted: 2025-07-30T12:11:19.848000+00:00
Original source

You might also need to check inside knockback from impl

rektbyfaith
Administrator
0
07-30-2025, 12:12 PM
#10
Archived author: Crane • Posted: 2025-07-30T12:12:06.854000+00:00
Original source

No, it's not a dungeon or world boss, and the NPC isn't rooted either, because he follows me and attacks me. I've already checked all of that.
rektbyfaith
07-30-2025, 12:12 PM #10

Archived author: Crane • Posted: 2025-07-30T12:12:06.854000+00:00
Original source

No, it's not a dungeon or world boss, and the NPC isn't rooted either, because he follows me and attacks me. I've already checked all of that.

Pages (2): 1 2 Next
Recently Browsing
 1 Guest(s)
Recently Browsing
 1 Guest(s)