Notifications
Clear all
[Closed] Struct problem
Aug 28, 2008 7:40 pm
[font=Verdana][size=2][color=white]I want to make my own Box().
I wrote a script below
aa.name = “ooooooooo”
It doesn’t work.
I don’t get what’s wrong with it.
[/size][/color][/font]
clearListener()
struct testBox
(
mybox = box(),
name = mybox.name,
width = mybox.width,
Length = mybox.Length,
Height = mybox.Height
)
aa = testBox()
aa.name = "ooooooooo"
3 Replies
1 Reply
Those commas are supposed to be there; without them, maxscript shouts profanities* at you
-- Syntax error: at name, expected )
-- In line: name =
The code works just fine… but, onetera, if you want to change the name of the actual box generated, you need to use:
aa.mybox.name = "aaaaaaaa"
The .name in your struct has no direct correlation to the name of the object in myBox whatsoever.