Water waves
			1 post			 • Page 1 of 1		
	
Water waves
I've find that way of simulating waves is the best in term of realistic/lag.
Waves simulated by two polygons with scripted pos:
pos = {[(sim.time * 2) % 10 + 10 * math.toInt(Scene.Camera.pan(0) / 10), 0]}
and
pos = {[5 + ( - sim.time * 3) % 10 + 10 * math.toInt(Scene.Camera.pan(0) / 10), 0]}
that waves pattern are always follow camera.
			Waves simulated by two polygons with scripted pos:
pos = {[(sim.time * 2) % 10 + 10 * math.toInt(Scene.Camera.pan(0) / 10), 0]}
and
pos = {[5 + ( - sim.time * 3) % 10 + 10 * math.toInt(Scene.Camera.pan(0) / 10), 0]}
that waves pattern are always follow camera.
Dream of Algodoo as game development engine...
		- 
				

Kilinich - [Best bug reporter 2010]
 - Posts: 2098
 - Joined: Mon Aug 31, 2009 8:27 pm
 - Location: South Russia
 
			1 post			 • Page 1 of 1		
	Who is online
Users browsing this forum: No registered users and 3 guests

			


