Notifications
Clear all

[Closed] stupid Debugging question

If one gets the following message in the listener, with no other diagnostics…

>> MAXScript Script Controller Exception: – Unknown system exception <<

… Is there any way to tell what exactly caused it? It happens one or more times on file load on some of my MxS plugin related scenes, and i can’t figure out where it’s coming from… Everything works fine bar the message being generated?

Cheers

Mikie

10 Replies

The only way I know of is just the brute force way. You’d have to go into the scripts/plugins and look for stuff related to controllers I guess. Sorry it’s not of much help. Maybe Dennis knows of a method, but I’m not sure there is one. : \

I’ve managed to establish that it’s not directly script related… it’s something my scripts end up doing to certain objects. When max later loads these objects, it causes some kind of internal script/controller fault…

Through a very tedious process of elimiation (restarting max on each attempt, as once something causes the fault to come up it comes up, it comes up on EVERY file load for that session, irrespective of what subsiquent files contain) i’ve narrowed down the object that causes it fault, but am yet to nail down the exact cause…

wanna take a look? Happens in both max 2011 and 2012… (though 2011 generates one error, and 2012 generates 2)

… if i delete the first index of custom attributes, then the error doesn’t show up on subsiquent loads… No idea why tho… I can’t see what is different betwen this scripted attribute def and any other that i use… it’s just a couple nodeTabs, a boolTab, and an intTab…


MaxObject: Group Params:Group Params

prop: #borderObj | value: #(undefined, undefined) | type: ArrayParameter
prop: #bPtObj | value: #(undefined, undefined) | type: ArrayParameter
prop: #errorState | value: #(false, false, false, false, false, false) | type: ArrayParameter
prop: #cI | value: #(1) | type: ArrayParameter

can you post the code of the scripted attribute?

1 Reply
(@mikiek)
Joined: 2 years ago

Posts: 0

GroupObjAttributes = attributes "Group Params"
(
	parameters main
	(
		borderObj type:#nodeTab tabSizeVariable:true 
		bPtObj type:#nodeTab tabSizeVariable:true 
		errorState type:#boolTab tabSize:6
		cI type:#intTab tabSizeVariable:true 
	)
	
)

i can’t open max file. i don’t use max 2011, 2012.
as i see the custom attribute itself can’t cause the error. do you have any callback script that reads (reset, updates) the attribute’s properties?

1 Reply
(@mikiek)
Joined: 2 years ago

Posts: 0

No, i’ve disabled all that stuff for testing… (as far as I can tell)

This happens the moment the file is loaded. (when any of my callbacks would be disabled anyways)

I’ve attached the 2010 version if tyou have that one?

i’ve checked the file. definitely something very weird with it.
i have an error message about bad script controller
i couldn’t find any trace of any scripted controller in this file

not any CA can cause the problem. i checked all persistent globals… they are clean…
i don’t like to be f*cked by MAX. so i’ll try to get the answer.

Thanks!

I’ve been pulling my hair out trying to figure out what the cause is.

Really need to buy that ADN membership methinks…

Figured out what the cause was…

The .cI property in an intTab (tabSizeVariable:true)

at one point in my plugin I empty the array using

$.cI = #()

This causes max to generate the unknown script exception, which is triggered any time any susiquent file gets loaded… even if it contains completely different objects until a ‘reset’ is performed, or if max is restarted.

the same thing happens if you try

$.cI.count = 0

What I found odd when i looked closer, was that .cI was being initialized to a size of 6…
It looks like this was taken from the parameter above it in my defenition. So i moved the fixed Tab size defenition to the end of my attribute defenition. … and now the unknown exception isn’t happening… In some lucky co-incidence the other 23 attribute defenitions in my plugin have the fixed tab size paramters after variable ones anyways…

There’s either a lesson to be learned here, or a bug…

Mikie