#Error during vampire survivors tutorial “invalid get index”

1 messages · Page 1 of 1 (latest)

plush valley
#

Remove your second line of indents and see if it works

hidden fable
#

@plush valley

plush valley
#

Mind showing me your errors?

plush valley
#

It could also help to jump back in the video and compare what you have to what is shown

hidden fable
#

My code in this node is exact same as video so I’m not sure

plush valley
#

Is your hierarchy the same as the one shown in the video?

#

The errors are implying that the player node is not a child of Game, which is the top node in the hierarchy

#

OH

#

If your hierarchy is fine, try adding a / before root on line 4

#

See if that works

hidden fable
#

Still doesn’t seem to work

plush valley
#

It seems like there's a breakpoint on line 8, click the red circle

plush valley
#

The red circle to the left of line 8 I mean

hidden fable
#

When I click it the breakpoint thing is what pops up

plush valley
#

Did the red circle on line 8 go away after you clicked it?

hidden fable
#

Oh wait this happened

plush valley
#

I see another error popped up, let's take a look

hidden fable
#

Sure

#

Also this is what my code looks compared to the video

plush valley
#

Show me your hierarchy, just in case

plush valley
#

In the hierarchy you showed in the first image, drag the player node onto the game node
Player is currently a child of ColorRect, which is hiding it from mob.gd

hidden fable
#

It works now

#

Thx a lot for the help! :D

#

Sorry it was taking so long haha

plush valley
#

Awesome! The ordering of your nodes is very important godette_smile

#

Also, here is a tip for taking screenshots
Windows Key + G -> Click the camera under the capture section

#

Then you can go to "See my captures" and clickdrag images into discord

#

Beats taking pictures on your phone