Seite 1 von 1

MaxScript: Change Handler

Verfasst: 22.04.2007, 13:48
von Simon
it's important to use the id to get access to the properties of the selected objects. if you use $.name you will get errors. if you use id.name (in this case obj.name) then all will fine.

Code: Alles auswählen

--call back
--change handler

--callbacks.addScript #modPanelSelChanged (
--	messagebox("selection changed");
--) id:#getinfos
rollout info "get scene/object information"
(

on info open do
(
	when select $objects changes obj do
	(
		$Text01.text = obj.name as string;
	)
)

on info close do
(
	deleteAllChangeHandlers()
)

)


CreateDialog info 150 150

Verfasst: 22.04.2007, 14:46
von Cornelius
all will "be" fine :wink:

Verfasst: 22.04.2007, 17:41
von Simon
war nur ein test um zu gucken obs jemand liest ;) hehe