Wednesday, 17 October 2012
DSDN142 - Creating the water
When i went home for a funeral this past week, i managed to catch up with my brother, who had done computer science for three years. He helped me out in some code that i was stuck on that would create the wavelike interaction that i was looking for. The code i had create was rubbish. Long, cluttered, some things weren't even necessary. He helped me to tidy it up and make it a lot shorter and precise, and also remove the need to have the block rectangles. Now there is a flow through the water that can be manipulated by dragging the mouse with the button held down or sending out a ripple to either side by clicking in one spot. Also, larger ripples are sent out to the side when you drag the mouse upwards. (Shown in the images above) One issue that arose from this code that im unsure how to fix, is that the screen will go crazy if dragged to far (left)
Subscribe to:
Post Comments (Atom)




No comments:
Post a Comment