❔ Help with unity line render
OK OK so i have an issue i made myself a grappling hook and well the line renderer isnt appearing or spawning yk
33 Replies
Please use $paste
If your code is too long, you can post to https://paste.mod.gg/ and copy the link into chat for others to see your shared code!
Easier to see code
BlazeBin - chvbbswgcrml
A tool for sharing your source code with the world!
does that help??
What is the exact issue you're seeing?
are you getting an exception/
there is no like issues its js not appearing when im grappling onto an object
I see
hmm
Ok
its not rlly spawning either
have you confirmed that
DrawRope
is getting past the early return?no how lmao
im new to this ngl
assuming you're using Visual Studio 2022, there is a debugger built in
you can set a breakpoint and just have a look
how do i set a breakpoint?
Use breakpoints in the debugger - Visual Studio (Windows)
Learn about breakpoints, one of the most important debugging techniques. The article covers breakpoint actions, tracepoints, conditions, and much more.
this can explain it better than I can, methinks 🙂
where do i put the break point??
where you want the code to pause
so, on the if statement with the early return
I'd imagine
or maybe after if its being invoked every frame
here
??
im getting this now
ah
the index is out of bounds
the game will stop working as you expect once an exception is thrown
what u mean
C# angy when you play the game
because you're doing something it can't recover from
basically
so how do i fix that?
does the line renderer not have a way to just add a position as opposed to setting one?
alternatively you can just set indices 0 and 1 to be Vector3.zero
where?
it does
ehhhhm
at this point I would need to basically have the project in front of me and debug it myself
I think
which I uh
well
don't really have time to be doing, understandably
all good
ill try figure it out myself
my advice is basically just inspect via the debugger see what you can find out what's up
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.