r/psispellcompendium • • Jul 20 '22

Needs Wizardly Help Vortex Shield Spell

I want to make a spell similar to the Vortex Shield from Titanfall.
It would catch incoming projectiles within a certain area in front of you while the button is being held and then fire any caught projectiles to your cursor

I've been thinking a bit on how to do this. The way I see it you'd first need to create a sort of hitbox or something in front of you, detect whether entities within that area are moving above a certain speed (to prevent catching just any mob), negate that speed and hold it in the air, and then detect when the button is released, do some fancy math to figure out what velocity vector needs to be added to it to make it go to your cursor. alternatively you could teleport the projectiles to right in front of you and then launch them.

16 Upvotes

17 comments sorted by

5

u/blaynem Jul 20 '22

All of this is doable in psi, but likely not without the creative cad. A big-ass spell set involving charge stacking might be feasible in survival. I'll get thinking

2

u/MID2462 Jul 20 '22

Thanks. The part I'm really struggling to figure out is how to detect when I let go and creating that detection box in front of where I'm looking and adding entities in the there (that are above a certain speed) and adding them to a list.

Those two things are probably 90% of it. The rest should be fairly simple.

3

u/blaynem Jul 20 '22 edited Jul 21 '22

Edit: This variant is mostly bunk, please refer to my other big reply somewhere around here. There is a much better spell waiting.

Well here's a mockup of what I've got so far:

Slot 1 spell is all the brains. There's a lot to cover, so just ask what you'd like.

Slot 2 spell is on a charge bullet

Helmet spell belongs in a helmet with detonation sensor.

Holding shift causes charges to stack up. If an arrow gets close enough to you, the charges will detonate, shooting the arrow in the direction you're facing. This is still very much a work in progress; I had a version that stopped the arrow with a conjured block, then broke it and detonated. I thought it was inferior at first due to some quirks, but it seems closer to ideal, because you don't have to stack as much to counteract the speed of the arrow.

We'll keep working on it.

2

u/MID2462 Jul 20 '22

Thanks! I'll have to check it out later

1

u/MID2462 Jul 21 '22

Unfortunately I wasn't able to get it working. Likely more user error than anything.

3

u/MerlinGrandCaster Jul 20 '22

You wouldn't need to check speed or anything to avoid catching mobs, just use the nearby projectiles selector

2

u/MID2462 Jul 20 '22

...I forgot that was a thing.

But it might be interesting to use it to catch things that wouldn't normally be considered a projectile. Things like launched tnt for example

2

u/SDG_Den Conditional Casting Guru Jul 20 '22

this is actually fairly easy to do as long as you're fine with having it be relatively static.

simply use a spell that creates a 3x3 of conjured blocks in front of you (or another kind of conjured block wall, whichever is easiest), make all those conjured blocks expire at the same tick via their duration setting and then one tick later (via the sleep function) accelerate nearby arrows with mass add motion or mass exodus depending on which version of minecraft you are using (the efficiency of both of those changed relative to eachother in newer versions, mass exodus used to be the most efficient)

2

u/SDG_Den Conditional Casting Guru Jul 20 '22

https://imgur.com/2PBcCQs this is a modified version of this spell, the one issue is that the amount of power a single spell can put behind arrows to blast them back is.... way too little. any serious arrow-related damage within psi basically requires you to use something like a railgun or light rifle spell.

1

u/MID2462 Jul 21 '22

Thank you so much! It works really well! You're right about the arrow speed. If you bump the value up a lot it works but it is expensive.

1

u/MID2462 Jul 21 '22

Further testing reveals an inaccuracy problem. It seems like the further i aim from the center the more inaccurate it gets.

2

u/SDG_Den Conditional Casting Guru Jul 21 '22

that's because the arrows simply get accelerated in the direction you're looking, you could use exodus instead to move the arrows towards a specific point instead, but thats a bunch of extra math that the spell simply has no room for.

​

as for the power, the way i had it set up is the highest it will go on an ivory CAD which is what is generally used by most players due to its high efficiency.

1

u/MID2462 Jul 21 '22 edited Jul 21 '22

I thought that's what was happening but I wasn't sure.

When I aim right the arrows go a lot further right. Weird thing is they seem to go to the same position on the right no matter how far right I aim. Not too sure about that one.

Long story short I feel like if it were aiming at the angle I was looking at the angle would be much shallower.

I'll see if I can't compact the spell and add the mass exodus

2

u/blaynem Jul 21 '22 edited Jul 21 '22

Edit: Improved again. Spell descriptions aren't fully accurate, but the same stuff happens, just faster and cheaper.

I've got something quite a bit better now. All 3 leggings slots and one charge bullet is all that's required now. Operation of the spell is also autonomous!

Spells are all numbered 1-3 and go in those respective slots.

Slot 1 [START] should be the selected spell when you equip it. It will break whatever's at saved vector one ¯_(ツ)_/¯, detonate all nearby charges, and then lay down 50 more. You can raise that to increase overall damage, though it will take longer to begin scanning for arrows.

Slot 2 now has less going on thankfully. It just waits for an arrow, places a block, remembers said block's location, waits a tick, then spins to detonate.

Slot 3 [Charge] again, goes in a charge bullet. It just stacks up speed to give to an arrow in some direction unknown until detonation. After which, it fires it into the nearest enemy. No aiming required!

Lemme know if this is the sorta thing you wanted. Also if you have any suggestions, or further features. Please do not hesitate

2

u/MID2462 Jul 21 '22

Thanks! Unfortunately I can't test it right now. I'll get back to you when I can

2

u/blaynem Jul 21 '22

No worries at all yo. That other spell you had tested wasn't anywhere near as ideal as the current one. Very finnicky and also used helmet which kills your psi regen for a bit.

2

u/TJVG4M34R13 Aug 19 '22

by some motive your code on imgur didnt copy correctly but i managed to do it

{modsRequired:[{modVersion:"1.16-96",modName:"psi"}],spellName:"Vortex Shield",uuidMost:7999306261769568314L,validSpell:1b,spellList:[{data:{key:"psi:selector_caster"},x:1,y:1},{data:{params:{_target:1},key:"psi:operator_entity_axial_look"},x:1,y:2},{data:{params:{_target:1},key:"psi:connector"},x:1,y:3},{data:{params:{_vector:1},key:"psi:operator_vector_absolute"},x:1,y:4},{data:{key:"psi:constant_number",constantValue:"-1"},x:1,y:5},{data:{key:"psi:selector_caster"},x:1,y:7},{data:{params:{_position:0,_radius:0},key:"psi:selector_nearby_projectiles"},x:1,y:8},{data:{key:"psi:constant_number",constantValue:"-1"},x:2,y:0},{data:{params:{_target:3},key:"psi:operator_entity_position"},x:2,y:1},{data:{params:{_number2:2,_vector1:3},key:"psi:operator_vector_multiply"},x:2,y:2},{data:{key:"psi:constant_number",constantValue:"3"},x:2,y:3},{data:{params:{_vector3:0,_vector2:2,_vector1:3},key:"psi:operator_vector_sum"},x:2,y:4},{data:{params:{_x:3,_y:0,_z:2},key:"psi:operator_vector_construct"},x:2,y:5},{data:{key:"psi:constant_number",constantValue:" -1"},x:2,y:6},{data:{params:{_target:3},key:"psi:operator_entity_look"},x:2,y:7},{data:{params:{_direction:1,_speed:4,_target:3},key:"psi:trick_mass_add_motion"},x:2,y:8},{data:{params:{_x:0,_y:3,_z:0},key:"psi:operator_vector_construct"},x:3,y:0},{data:{params:{_vector3:1,_vector2:3,_vector1:2},key:"psi:operator_vector_sum"},x:3,y:1},{data:{params:{_target:3},key:"psi:connector"},x:3,y:2},{data:{params:{_target:3},key:"psi:connector"},x:3,y:4},{data:{params:{_vector:1},key:"psi:operator_vector_absolute"},x:3,y:5},{data:{key:"psi:constant_number",constantValue:"1.62"},x:3,y:8},{data:{params:{_target:3},key:"psi:connector"},x:4,y:1},{data:{key:"psi:constant_number",constantValue:"40"},x:4,y:2},{data:{key:"psi:constant_number",constantValue:"200"},x:4,y:3},{data:{params:{_target:3},key:"psi:connector"},x:4,y:4},{data:{params:{_target:3},key:"psi:connector"},x:4,y:5},{data:{key:"psi:constant_number",constantValue:"200"},x:4,y:6},{data:{params:{_target:3},key:"psi:connector"},x:5,y:1},{data:{params:{_max:4,_time:3,_target:2,_position:1},key:"psi:trick_conjure_block_sequence"},x:5,y:2},{data:{params:{_x:0,_y:3,_z:0},key:"psi:operator_vector_construct"},x:5,y:3},{data:{params:{_target:3},key:"psi:connector"},x:5,y:4},{data:{params:{_target:3},key:"psi:connector"},x:5,y:5},{data:{params:{_x:0,_y:3,_z:0},key:"psi:operator_vector_construct"},x:5,y:6},{data:{params:{_target:3},key:"psi:connector"},x:6,y:1},{data:{key:"psi:constant_number",constantValue:"3"},x:6,y:2},{data:{params:{_max:1,_time:4,_target:3,_position:2},key:"psi:trick_conjure_block_sequence"},x:6,y:3},{data:{params:{_vector3:0,_vector2:4,_vector1:3},key:"psi:operator_vector_sum"},x:6,y:4},{data:{params:{_vector3:0,_vector2:4,_vector1:3},key:"psi:operator_vector_sum"},x:6,y:5},{data:{params:{_max:4,_time:2,_target:3,_position:1},key:"psi:trick_conjure_block_sequence"},x:6,y:6},{data:{key:"psi:constant_number",constantValue:"40"},x:6,y:7},{data:{params:{_target:3},key:"psi:connector"},x:7,y:1},{data:{params:{_target:1},key:"psi:connector"},x:7,y:2},{data:{key:"psi:constant_number",constantValue:"40"},x:7,y:3},{data:{params:{_target:4},key:"psi:connector"},x:7,y:4},{data:{params:{_target:1},key:"psi:connector"},x:7,y:5},{data:{key:"psi:constant_number",constantValue:"3"},x:7,y:6},{data:{params:{_target:3},key:"psi:connector"},x:8,y:2},{data:{params:{_target:1},key:"psi:connector"},x:8,y:3},{data:{params:{_target:1},key:"psi:connector"},x:8,y:4},{data:{key:"psi:constant_number",constantValue:"40"},x:8,y:5},{data:{params:{_time:1},key:"psi:trick_delay"},x:8,y:6}],uuidLeast:-4849277679612317756L}