Changes between Version 4 and Version 5 of en/ProgrammingRobotsCourse/GettingWwwInfo
- Timestamp:
- Oct 28, 2019, 4:51:24 PM (4 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
en/ProgrammingRobotsCourse/GettingWwwInfo
v4 v5 35 35 36 36 (Full example attachment:news.py) 37 38 == How to integrate info with robot? 39 40 === Dialog variables 41 42 In dialog file, set value of variable, use it in Python script in behavior. 43 44 {{{#!python 45 u:(["Můj [oblíbený nejoblíbenější] tým je" "Fandím {týmu}"] _*) $team=$1 46 }}} 47 48 First word after sentence is available in {{{$1}}} and passed to the script as {{{team}}} variable. 49 50 {{{#!python 51 def onInput_onStart(self, team): 52 self.team_usr = team 53 }}}