-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsensor.rb.xml
More file actions
58 lines (58 loc) · 2.05 KB
/
sensor.rb.xml
File metadata and controls
58 lines (58 loc) · 2.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<xml xmlns="http://www.w3.org/1999/xhtml">
<character x="0" y="74" name="cat1" costumes="cat3.png" angle="0"></character>
<character x="290" y="298" name="cat2" costumes="cat1.png" angle="0"></character>
<character x="396" y="264" name="frog1" costumes="frog1.png" angle="0"></character>
<block type="ruby_comment" x="-401" y="-297">
<field name="COMMENT">距離センサー</field>
</block>
<block type="hardware_init_hardware" x="-404" y="-246"></block>
<block type="character_new" x="-426" y="-178">
<field name="NAME">cat1</field>
<statement name="DO">
<block type="events_on_start">
<statement name="DO">
<block type="control_loop">
<statement name="DO">
<block type="motion_set_x" inline="true">
<value name="X">
<block type="operators_minus" inline="true">
<value name="A">
<block type="hardware_sensor_value">
<field name="PIN">A0</field>
</block>
</value>
<value name="B">
<block type="math_number">
<field name="NUM">100</field>
</block>
</value>
</block>
</value>
</block>
</statement>
</block>
</statement>
</block>
</statement>
</block>
<block type="character_new" x="-421" y="54">
<field name="NAME">cat2</field>
<statement name="DO">
<block type="events_on_start">
<statement name="DO">
<block type="control_loop">
<statement name="DO">
<block type="looks_say" inline="true">
<value name="TEXT">
<block type="hardware_sensor_value">
<field name="PIN">A0</field>
</block>
</value>
</block>
</statement>
</block>
</statement>
</block>
</statement>
</block>
</xml>