#Stuck on a weird error

40 messages · Page 1 of 1 (latest)

pastel escarp
#

The Code

local x = 0
    while newDrop.Parent == workspace.DropedItems do
        local newPosition = CFrame.new(newDrop:GetPivot().Position + Vector3(0, math.sin(x),0))
        newDrop:PivotTo(newPosition * CFrame.fromEulerAngles(0,1,0))
        x+= .1
        task.wait()
    end```

Im getting a `Attempt to call a table value` error on line 4. I can not for the life of me find why
fresh crag
#

Which line

pastel escarp
#

the 4th in the photo

fresh crag
#

Pink newdrop

#

Print

pastel escarp
#

Its a Model

fresh crag
#

Print it and show what it says

pastel escarp
#

It prints the name of the model

#

Sorry, line 13 is erroring

uncut masonBOT
#

studio** You are now Level 6! **studio

fresh crag
#

☹️

pastel escarp
#

?

fresh crag
#

Delete the getpivot thing and tell me if it stops erroring

#

Its like 2 am I don’t have the brain power to rlly read code rn

pastel escarp
#

wait, I fixed it

#

I forgot to put .new after vector on line 13

#

like I said, felt like it was something simple

fresh crag
#

Oh

#

Its cuz you didn’t do .new

#

Yeah

pastel escarp
#

but I have a new problenm now

fresh crag
#

I just noticed

#

Wor

#

Show am eepy

pastel escarp
#

heres the code

#

let me get the resaults 2 secs

fresh crag
pastel escarp
#

also its not rotating

#

fuck im so sorry

fresh crag
#

Cuz your making a new cframe everytime with a rotation of 0,1,0

pastel escarp
#

i fixed everything

fresh crag
#

Ur not adding to its rotation

#

K im sleeping

pastel escarp
pastel escarp
#

Final code

woeful dome
#

cool code