Deleting an Array? Maybe!
Hi!
Just a quick question, I hope you can help, I'm not fantastically literate in Maxscript and am struggling with deleting my object.
I have got my sphere to rotate etc up to a certain point and my faces to "burst" outwards, however I then need it to delete from my scene at something like frame 75.
Any chance anybody could give me a hand with what I need to add to the end.
Everything I've tried so far just seems to delete my object before its even appeared.
Thanks!
(
obj = sphere()
scale obj [0.5,0.5,0.5]
convertToPoly obj
for f in (obj.faces as bitarray) do polyop.detachFaces obj f
mapped fn moveFace f =
(
obj.selectedFaces = #{f}
fNormal = polyop.getFaceNormal obj f
fCenter = polyop.getFaceCenter obj f
move obj.selectedFaces (fCenter+(fNormal*100))
)
animate on at time 40 obj.pos = [80,0,60]
animate on at time 70 moveFace ((obj.faces as bitarray) as array)
animate on at time 70 rotate obj (angleaxis 360 [0,0,6])
)
Comments
That's exactly the tracks on
That's exactly the tracks on the i need to be on! Thanks for your help...I really appreciate it :)
cheers again :)
i've made a small edit in
i've made a small edit in code below.
Remove line "deleteObjFace = polyop.deleteFaces".
bga
maybe someone else has a
maybe someone else has a better solution for this,
But you can try this.
You may not see the difference in viewport but in animation your object
will disappear when timeslider cross the 75 frame.
Deleting faces is not smart move.Is also slow.
I've suggest to use visibilyty controller.
This is your code:
bga
You don't twice call "animate
You don't twice call "animate on at time 70" do it like this
If I understood you well you need to delete all faces at frame 75?
Maybe this?
bga
Thanks for cleaning up my
Thanks for cleaning up my animate part.
the code you have suggested...call me stupid, but where do i need to include this? you're right i do want to delete all the faces at frame 75, but this code doesnt say frame 75 in it?
i'm sorry...very new at this!
Thanks :)