Ask coding questions

← Back to all posts
Why doesn't my function work?
YunusKaya1

I'm trying to make a 3d engine, but for some reason when I try to call this function it doesn't work?
vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv

def goTo(x, y, z):
t.goto(FOV((X+CamX)/(Z+CamZ),FOV ((Y+CamY)/(Z+CamZ))

goTo(50, 20, 30)


it gives me an error
vvvvvvvvvvvvvvvvvvvvvv

File "main.py", line 16
goTo(50, 20, 30)
^
SyntaxError: invalid syntax

Voters
YunusKaya1
Comments
hotnewtop
Coder100

You forgot a closing parentheses on line 14

CosmicBear

It's supposed to be this: t.goto(FOV((X+CamX)/(Z+CamZ),FOV ((Y+CamY)/(Z+CamZ))))

AmoghTheCool

@CosmicBear wow you understand 3d? I never did :(

CosmicBear

@AmoghTheCool i don't understand 3d. I just counted the brackets.