>xabsl
Behavior Documentation
>
Index
>Agents
>Symbols
>Basic Behaviors
>Options
>> kick_demo
>>>
stand
>>>
grab_ball_with_head_fast
>>>
grab_ball_with_head_direct
>>>
wait_for_kick
>>>
head_kick_from_grab_soft
>>>
head_left
>>>
roll_over_neck_right
Option kick_demo
State Machine
This browser can't display the SVG file
svg/option_kick_demo.svg
.
The
Adobe SVG Viewer 3.0
can be downloaded from
http://www.adobe.com/svg/viewer/install/main.html
State stand
If that state is active,
>
This enumerated output symbol is set:
head.control_mode
=
head.control_mode.look_straight_ahead
>
This enumerated output symbol is set:
motion.type
=
motion.type.stand
The decision tree:
This browser can't display the SVG file
svg/option_kick_demo_state_stand.svg
.
The
Adobe SVG Viewer 3.0
can be downloaded from
http://www.adobe.com/svg/viewer/install/main.html
Pseudo code of the decision tree:
/** */
if
(
(
switch.hind_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
stand
;
}
else
{
/** */
if
(
(
switch.fore_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
grab_ball_with_head_fast
;
}
else
{
/** */
if
(
(
switch.middle_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
wait_for_kick
;
}
else
{
stay;
}
}
}
State grab_ball_with_head_fast
If that state is active,
>
The option
grab_ball
is executed.
The decision tree:
This browser can't display the SVG file
svg/option_kick_demo_state_grab_ball_with_head_fast.svg
.
The
Adobe SVG Viewer 3.0
can be downloaded from
http://www.adobe.com/svg/viewer/install/main.html
Pseudo code of the decision tree:
/** */
if
(
(
switch.hind_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
stand
;
}
else
{
/** */
if
(
action_done
)
{
goto
wait_for_kick
;
}
else
{
/** */
if
(
(
switch.fore_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
wait_for_kick
;
}
else
{
stay;
}
}
}
State grab_ball_with_head_direct
If that state is active,
>
The option
grab_ball_with_head_direct
is executed.
The decision tree:
This browser can't display the SVG file
svg/option_kick_demo_state_grab_ball_with_head_direct.svg
.
The
Adobe SVG Viewer 3.0
can be downloaded from
http://www.adobe.com/svg/viewer/install/main.html
Pseudo code of the decision tree:
/** */
if
(
(
switch.hind_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
stand
;
}
else
{
/** */
if
(
action_done
)
{
goto
wait_for_kick
;
}
else
{
/** */
if
(
(
switch.fore_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
stand
;
}
else
{
stay;
}
}
}
State wait_for_kick
If that state is active,
>
This enumerated output symbol is set:
head.control_mode
=
head.control_mode.grab_ball
>
This enumerated output symbol is set:
motion.type
=
motion.type.stand
The decision tree:
This browser can't display the SVG file
svg/option_kick_demo_state_wait_for_kick.svg
.
The
Adobe SVG Viewer 3.0
can be downloaded from
http://www.adobe.com/svg/viewer/install/main.html
Pseudo code of the decision tree:
/** */
if
(
(
switch.hind_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
stand
;
}
else
{
/** */
if
(
(
switch.fore_back_button_pressed_short_and_released
()
)
&&
(
state_time
> 1000
)
)
{
goto
head_kick_from_grab_soft
;
}
else
{
/** */
if
(
(
switch.middle_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
head_left
;
}
else
{
/** */
if
(
(
switch.any_back_button_pressed_for_one_second
()
)
&&
(
state_time
> 1000
)
)
{
goto
roll_over_neck_right
;
}
else
{
stay;
}
}
}
}
State head_kick_from_grab_soft
If that state is active,
>
The option
special_action
is executed. Parameters:
special_action.id
=
motion.special_action.forward_kick_fast ;
special_action.mirror
=
false ;
The decision tree:
This browser can't display the SVG file
svg/option_kick_demo_state_head_kick_from_grab_soft.svg
.
The
Adobe SVG Viewer 3.0
can be downloaded from
http://www.adobe.com/svg/viewer/install/main.html
Pseudo code of the decision tree:
/** */
if
(
(
switch.hind_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
stand
;
}
else
{
/** */
if
(
action_done
)
{
goto
stand
;
}
else
{
stay;
}
}
State head_left
If that state is active,
>
The option
special_action
is executed. Parameters:
special_action.id
=
motion.special_action.head_left ;
The decision tree:
This browser can't display the SVG file
svg/option_kick_demo_state_head_left.svg
.
The
Adobe SVG Viewer 3.0
can be downloaded from
http://www.adobe.com/svg/viewer/install/main.html
Pseudo code of the decision tree:
/** */
if
(
(
switch.hind_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
stand
;
}
else
{
/** */
if
(
action_done
)
{
goto
stand
;
}
else
{
stay;
}
}
State roll_over_neck_right
If that state is active,
>
The option
special_action
is executed. Parameters:
special_action.id
=
motion.special_action.roll_over_neck_left ;
special_action.mirror
=
true ;
The decision tree:
This browser can't display the SVG file
svg/option_kick_demo_state_roll_over_neck_right.svg
.
The
Adobe SVG Viewer 3.0
can be downloaded from
http://www.adobe.com/svg/viewer/install/main.html
Pseudo code of the decision tree:
/** */
if
(
(
switch.hind_back_button_pressed
()
)
&&
(
state_time
> 1000
)
)
{
goto
stand
;
}
else
{
/** */
if
(
action_done
)
{
goto
stand
;
}
else
{
stay;
}
}