资源预览内容
第1页 / 共27页
第2页 / 共27页
第3页 / 共27页
第4页 / 共27页
第5页 / 共27页
第6页 / 共27页
第7页 / 共27页
第8页 / 共27页
第9页 / 共27页
第10页 / 共27页
亲,该文档总共27页,到这儿已超出免费预览范围,如果喜欢就下载吧!
资源描述
Exploring Visual Programming,Preliminaries,The purpose of this document is to introduce you to SimBuilder by helping you create a small project. SimBuilder is designed for building simulations, such as a model of the water cycle. No programming experience is required. In this experiment we want to evaluate the usefulness of this tool to a science teacher to simulate environments or lab experiments as curricula aids in their classrooms with SimBuilder. The last page of this document contains an interaction guide.,http:/www.tdzl.net/ 天津塔吊租赁 河北塔吊租赁 西安塔吊租赁 塔吊租赁 http:/www.u51688.com/,Exploring the Water Cycle Model,Double click to open the Squeak environment. Select Water Cycle This will open your first example of a simulation. Now, Press to start this model. Watch the Simulation. What actions are taking place? Press after a few minutes of observing the model. Squeak SimBuilder Tutorial Virginia Tech Visual Languages Group AgentSheets Tutorial Virginia Tech Visual Languages Group-Draft,Squeak,Exploring The Sun,Lets investigate the players To investigate the Sun Click or Click the Sun and its Halo will appear. Select the purple eyedropper Change color tool to and change the Sun from yellow to bright orange. To investigate the rules or that govern the suns behavior, Select the blue eyeball to Open a Viewer of me. This will show you the set of graphical rules for this player. What does the Sun do? You program by simply selecting a rule, then dragging and dropping the out of the scripting window and placing it somewhere in the world other than the green playground. (Take a few minutes to explore scripts in the viewer) Squeak SimBuilder Tutorial Virginia Tech Visual Languages Group,Changing The Behavior of Clouds,Examine some of the more complicated behaviors by selecting the Cloud and reviewing its behavior. Take a moment to review the interaction guide to gain a better understanding of the interactions between agents behaviors Make Clouds more active. Currently the behavior of the cloud is to move forward 5 spaces. Find the script that causes this behavior. Lets make the clouds move a lot more. Click on the desired script Increase the value to 10 for moving forward. Press to see how your changes affect the simulation. Press and try another change. Make the clouds move vertically. Currently the behavior of the cloud is to move horizontally across the sky. Lets try to change the behavior of the cloud so that it will move vertically. Click or Click your cloud and its Halo will appear. Select Rotate and move your cloud just a tiny bit for its direction arrow to appear. In order to change the direction that the player moves Click on the green arrow and change its direction so that it points to the right. Press to see how the simulation has changed. Squeak SimBuilder Tutorial Virginia Tech Visual Languages Group,Creating a Bird,A simulation in Agentsheets is simply a set of agents that work together to create visual effects. A key aspect of creating new simulations is to build new agents. We will begin with the small task of adding a new agent to the Water Cycle project. Drawing a bird Select . Use a brush and the color palette to draw something that looks like a bird. Refer to the interaction guide for Gallery Tools if you need to refresh your memory. This is just for fun. Do not worry if you are not a good artist. Once finished Press . Your bird has been added to the playground. Its just as easy as that ! Squeak SimBuilder Tutorial Virginia Tech Visual Languages Group,Giving the Bird Behaviors,In this playground, we want the bird to be able to fly through the sky. Double click on your bird and its viewer will appear. The viewer is a window to select behaviors for your agent. Lets add the behavior that your agent will move in one direction. Select and Drag it out of the viewer and place it anywhere, preferably not in the playground. Press to see how your bird acts within the playground. Your bird should fly across the playground. If it doesnt you may need to check out which direction your bird is flying. Click or Click your bird and its Halo will appear. Select Rotate and move your bird just a tiny bit for its direction arrow to appear. Click on the green arrow and change its direction so that it points to the right. Try putting a bird on the ground. Does it move? What would you need to make it move? Now you have all the basic tools you need to create your own Simulations! Squeak SimBuilder Tutorial Virginia Tech Visual Languages Group,Creating a Volcano Simulation,A sample environment that you could simulate is a volcano erupting. A volcano involves the interaction of several complex factors. Pressure is built up over a period of time. Once the pressure reaches a certain level the pressure is released as sparks, smoke, lava, and heat.The lava causes the earth and the mountain to become larger
网站客服QQ:2055934822
金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号