Skip to content

getkey and explicit new xy - #56

Open
jkrauska wants to merge 1 commit into
evildmp:masterfrom
jkrauska:fix/explict_x_y_getkey
Open

getkey and explicit new xy#56
jkrauska wants to merge 1 commit into
evildmp:masterfrom
jkrauska:fix/explict_x_y_getkey

Conversation

@jkrauska

@jkrauska jkrauska commented Dec 1, 2019

Copy link
Copy Markdown
Contributor
  • Uses getkey instead of getchar to allow for arrow keys
  • sends new x and y coords to xy function to use steps (using self was calculating length 0)

@jkrauska jkrauska changed the title getkey and explict new xy getkey and explicit new xy Dec 2, 2019
@jkrauska

jkrauska commented Dec 9, 2019

Copy link
Copy Markdown
Contributor Author

@evildmp Any interest in this?

@evildmp

evildmp commented Dec 14, 2019

Copy link
Copy Markdown
Owner

I like the idea, but is there a way to prevent this from happening when a key is held down?

>>> bg.drive_xy()
X:-10.0, Y:7.0
PW1:1999, PW2:1393
^[[D^[[BX:-11.0, Y:7.0
^[[CPW1:1986, PW2:1293
^[[C^[[C^[[C^[[CX:-10.0, Y:7.0

It happens already with the a/s/k/l controls, but it's more obtrusive as above.

Also, the drive methods should be documented in /docs/reference/brachiograph.rst.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants