Anim8or Community

Please login or register.

Login with username, password and session length
Advanced search  

News:

Ian Ross has just released a book on Anim8or. It's perect for a beginner and a good reference for experienced users. It contains detailed chapters on every aspect, with many examples. Get your own copy here: "Anim8or Tutorial Book"

Author Topic: CMOD export script breaks under v0.97b, works with v0.97a  (Read 8117 times)

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
CMOD export script breaks under v0.97b, works with v0.97a
« on: June 20, 2008, 06:09:43 am »

The script I've been using to export CMOD models no longer works when run under v0.97b.
No error messages are generated.
It works fine with v0.97a.

The script writes two output files, one listing all materials, the other contains the mesh and vector lists.
An empty material file is written under v0.97b.

The script has not been changed since November 11, 2006.

It's available at http://www.lepp.cornell.edu/~seb/celestia/files/export_cmod_plugin.a8s
(500 lines, 17KB)
Logged
Selden

Steve

  • Administrator
  • Hero Member
  • *****
  • Posts: 2126
    • View Profile
Re: CMOD export script breaks under v0.97b, works with v0.97a
« Reply #1 on: June 20, 2008, 02:53:45 pm »

OK I'll look into it.
Logged

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
Re: CMOD export script breaks under v0.97b, works with v0.97a
« Reply #2 on: June 20, 2008, 02:59:26 pm »

Thanks!
s.
Logged
Selden

Steve

  • Administrator
  • Hero Member
  • *****
  • Posts: 2126
    • View Profile
Re: CMOD export script breaks under v0.97b, works with v0.97a
« Reply #3 on: June 25, 2008, 02:16:19 am »

#097-012 - CMOD Export Script Stopped Working in v0.97b

I've found and fixed the problem.  When I added output to the $console in v0.97b I forgot to initialize the "IsConsole" flag on all code paths.  If it gets a non-zero (uninitialized) value for a file opened in a script,
like the material file in this one, the file wouldn't be closed and the last part of it (all of it for a small file like
material files) would be lost.

Thanks for reporting this! It also breaks the .obj export script and I'm sure a lot of others.  A fix will be in the next preview update.
Logged

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
Re: CMOD export script breaks under v0.97b, works with v0.97a
« Reply #4 on: June 25, 2008, 10:38:20 am »

Steve,

Thanks again.

Logged
Selden