Go Back   AC3D Forums > Resources > AC3D Scripts and Mods
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 6th January 2018, 11:23 AM   #1
SpitForty
Junior Member
Member
 
Join Date: Jan 2018
Posts: 24
Default Creating objects in TCL script

I've just started working with AC3D scripts and have found selection & rotation type functions really useful on objects. But please, how do I make objects - in particular a mesh? The only object creation I've found is a cube, but I'd like to autogen a mesh of various sizes and then select and cut away surfaces.
SpitForty is offline   Reply With Quote
Old 10th January 2018, 02:38 PM   #2
Andy
Administrator
Professional user
 
Andy's Avatar
 
Join Date: Jun 2003
Posts: 4,563
Default Re: Creating objects in TCL script

There are no internal commands to create objects and add vertices and surfaces.

There is an old linecom plugin that comes with AC3D. From Help->about-plugins:

Code:
Line command plugin - Version 1.0 by Inivis

This plugin adds internal commands to AC3D.  Commands can be called from outside AC3D using various methods - see the SDK for more info.
commands added are:
line - start a line,
point <x> <y> <z> - add a point to the line
end - finish adding the line

note that you'll need to send the redraw_all command to make AC3D show the line that's been added.
I haven't tried it for a while so it may not still work but if it does, you could possibly use it. If you would like the source code for the plugin, let me know.
Andy is offline   Reply With Quote
Old 11th January 2018, 05:18 AM   #3
SpitForty
Junior Member
Member
 
Join Date: Jan 2018
Posts: 24
Default Re: Creating objects in TCL script

Quote:
Originally Posted by Andy View Post
There are no internal commands to create objects and add vertices and surfaces.

There is an old linecom plugin that comes with AC3D. From Help->about-plugins:

Code:
Line command plugin - Version 1.0 by Inivis

This plugin adds internal commands to AC3D.  Commands can be called from outside AC3D using various methods - see the SDK for more info.
commands added are:
line - start a line,
point <x> <y> <z> - add a point to the line
end - finish adding the line

note that you'll need to send the redraw_all command to make AC3D show the line that's been added.
I haven't tried it for a while so it may not still work but if it does, you could possibly use it. If you would like the source code for the plugin, let me know.
Thanks Andy. In the end I found it easier to build a basic mesh, work out the structure of the .ac code and build it outside AC3D. There seems to be a lot of scope for doing things that way.
SpitForty is offline   Reply With Quote
Old 11th January 2018, 06:26 AM   #4
Andy
Administrator
Professional user
 
Andy's Avatar
 
Join Date: Jun 2003
Posts: 4,563
Default Re: Creating objects in TCL script

That's good. You could also use the .tri file format which is really simple - a triangle on each line with an rgb col at the end.

Export something as .tri and have a look in the file to check the format.
Andy is offline   Reply With Quote
Old 11th January 2018, 07:36 AM   #5
SpitForty
Junior Member
Member
 
Join Date: Jan 2018
Posts: 24
Default Re: Creating objects in TCL script

Great. Will do thanks
SpitForty is offline   Reply With Quote
Reply

Tags
mesh, tcl

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



All times are GMT -4. The time now is 01:13 AM.


AC3D Forum
(C) Inivis Limited 2020