#need help

1 messages · Page 1 of 1 (latest)

final steppe
#

how do i do it when i use a fising rod it sets {cords} to the cordinates of the closest block that is in the direction i am looking at

next quest
#

you can use vectors or ray tracing

#

or maybe even just use the location of the bobber

final steppe
final steppe
next quest
#

heck, whats wrong with player's target block? its a but hard to know which method is best without a decent explanation of what this is being used for

final steppe
#

sry for caps

#

i need it to summon a tnt at the block the palyer is looking at

#

like ~ ~1 ~ of the block the palyer is looking at

#

so i need the cordinates of the block i look at

next quest
#

okay so yeah, player's target block should work then, no?

#

and just offset by vector(0,1,0)

final steppe
next quest
#

it will work

final steppe
#

it isnt?

next quest
#

!spawn creeper at (me's target block)

final steppe
#

it isnt working bcuz

next quest
#

it should indeed work

final steppe
#

{cords} becomes 'grass block' at -596.5, 71.5, 254.5 in world 'world'

#
  if event-player is "Apple00220":
    if player is holding a fishing rod:
      set {cords} to the player's target block
      execute console command "execute at %event-player% run fire {cords} stab 1 1 0 0"
      send "%{cords}%" to player```
#

is my code rn btw

#

wait am dumb excuse me

next quest
#

why in the world are you using console commands

final steppe
#

bcuz

next quest
#

on right-click with fishing rod: also

final steppe
#

its a portable stab shot like in unstable

final steppe
next quest
#

what does the command have to do with summoning tnt

final steppe
#

that command summons tnt from build limit to bedrock in a colum that instanlty explodes

#
  if event-player is "Apple00220":
    set {cords} to location of player's target block
    execute console command "fire {cords} stab 1 1 0 0"
    send "%{cords}%" to player```
#

but this gives x: -595.5, y: 71.5, z: 249.5, yaw: 0, pitch: 0 in 'world' to {cords}

next quest
#

well yeah you shouldnt be stringifying it

#

just summon tnt at {_LOCATION}

final steppe
final steppe
next quest
#

spawn primed tnt with skript

final steppe
#

but i need to

next quest
final steppe
#

thats not satisfying enough

next quest
#

?

final steppe
#

so its not possible to get the raw cordiantes of the block the palyer is looking at?

next quest
#

yes it is, but i dont think you need to

final steppe
#

just 3 numbers x y and z cords

final steppe
#

i installed a plugin at this point that makes it easy to config i should be using it lol

next quest
#

also, a simple docs search would work for this question...

Just use player's target block, and then you can loop in a vertical line and spawn tnt at every y value should you wish

next quest
#

and if the command spawns a vertical stack of tnt, it really only needs you to pass in x and z not y

final steppe
#

i am going to do other stuff to which i need the comand for

final steppe
#

I FIGURED IT OUT