Psi

Psi

48M Downloads

Entity raycast outputs player always

ANT83z4 opened this issue ยท 2 comments

commented

i made a few spells that use entity raycast check for entities that can't be detected by selectors (tnt, special minecarts etc) but in 1.19.2 they are all broken and output player instead. than i realised that the raycast couldn't output player in latest 1.16.5 version. I assume its a bug

Forge version:43.4.0
Psi version:2.0.0

Further Information

What I expected to happen:
entity raycast outputs tnt entity that i was looking at
What happened instead:
i got launched instead

commented

Linking related Issue 755

commented

This is intended. If an entity is right on top of the starting position of the raycast, it is considered the closest. To avoid this you can add the caster's axial look to the caster's position.

Image
{modsRequired:[{modName:"psi",modVersion:"1.21.1-106"}],spellList:[{data:{key:"psi:selector_caster"},x:3,y:3},{data:{key:"psi:connector",params:{_target:1}},x:3,y:4},{data:{key:"psi:connector",params:{_target:1}},x:3,y:5},{data:{key:"psi:connector",params:{_target:3}},x:4,y:3},{data:{key:"psi:operator_entity_position",params:{_target:1}},x:4,y:4},{data:{key:"psi:operator_entity_look",params:{_target:3}},x:4,y:5},{data:{key:"psi:operator_entity_axial_look",params:{_target:3}},x:5,y:3},{data:{key:"psi:operator_vector_sum",params:{_vector1:1,_vector2:3,_vector3:0}},x:5,y:4},{data:{key:"psi:operator_entity_raycast",params:{_max:0,_position:1,_ray:3}},x:5,y:5},{data:{key:"psi:trick_debug_spamless",params:{_number:0,_target:1}},x:5,y:6}],spellName:"Channeled Debug",uuidLeast:-7559203270116367294L,uuidMost:4864837952036162662L,validSpell:1b}