![]()  | 
	
		
 error while setting material properties. 
		
		
		Hi, 
	I get the following error while trying to set material attributes like sethardness() the function is called as follows an example code: import viz import vizmat viz.go() viz.translate(viz.HEAD_POS,0,5,-10) viz.lookat(0,0,0) ground = viz.add('ground.wrl') ground.collideplane() ball = viz.add('ball.wrl') ball.collidesphere() ball.sethardness(0.1) ball.reset() ground.reset() ball.translate(0,10,0) ball.scale(0.6,0.6,0.6) viz.phys.enable() When I try to run this code, I get the following error: Scaling image 'worlds/yellow.GIF' from (640,400) to (512,512) Traceback (most recent call last): File " File "myproj.py", line 14, in ? ball.sethardness(0.1) AttributeError: 'VizChild' object has no attribute 'sethardness' Scaling image 'worlds/blue.GIF' from (640,400) to (512,512)  | 
		
 setHardness is a method of VizPhysicsShape, not of VizNode/VizChild.  Check the example again. In addition, the case of the letters in the method mater. 
	Code: 
	ball = viz.add('ball.wrl')Check out this code to see multiple collide shapes: Code: 
	box = viz.add('box.wrl') | 
| All times are GMT -7. The time now is 06:42 AM. | 
	Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
	
	Copyright 2002-2023 WorldViz LLC