Skip to content

Instantly share code, notes, and snippets.

@jedie
Created April 15, 2012 13:14
Show Gist options
  • Save jedie/2392735 to your computer and use it in GitHub Desktop.
Save jedie/2392735 to your computer and use it in GitHub Desktop.
maxscript to turn off backface cull on all objects
--
-- copyleft (c) 2012 by htFX, Jens Diemer - http://www.htFX.de
--
-- https://gist.github.com/2392735
-- http://www.scriptspot.com/3ds-max/scripts/maxscript-to-turn-off-backface-cull-on-all-objects
--
actionMan.executeAction 0 "40472" -- MAX Script: MAXScript Listener
clearListener()
fn backfaceCullOff objs =
(
processed_obj = 0
changed_obj = 0
for obj in objs do (
processed_obj += 1
-- format "% - %\n" obj.backfaceCull obj
if (obj.backfaceCull==true) then
(
format "turn backface cull off for: %\n" obj
obj.backfaceCull = false
changed_obj += 1
)
)
format "% objects processed.\n" processed_obj
format "% objects changed.\n" changed_obj
)
with undo on (
backfaceCullOff $*
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment