Changes between Version 4 and Version 5 of en/ProgrammingRobotsCourse/GettingWwwInfo


Ignore:
Timestamp:
Oct 28, 2019, 4:51:24 PM (11 months ago)
Author:
xrambous
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • en/ProgrammingRobotsCourse/GettingWwwInfo

    v4 v5  
    3535
    3636(Full example attachment:news.py)
     37
     38== How to integrate info with robot?
     39
     40=== Dialog variables
     41
     42In dialog file, set value of variable, use it in Python script in behavior.
     43
     44{{{#!python
     45u:(["Můj [oblíbený nejoblíbenější] tým je" "Fandím {týmu}"] _*) $team=$1
     46}}}
     47
     48First word after sentence is available in {{{$1}}} and passed to the script as {{{team}}} variable.
     49
     50{{{#!python
     51def onInput_onStart(self, team):
     52    self.team_usr = team
     53}}}