GDQuest / GDQuest/learn-gdscript

20. Looping over arrays - Back to the Drawing Board; unfriendly leap in logic

Open
#720 2 comments 0 reactions 0 assignees View on GitHub
content
Dominant language
GDScript
Stars
2.8k
Forks
235
PR merge metrics
No merged PRs in 30d

Description

The Practice asks us to use a for loop to draw 4 rectangles using the pre-defined array. The practice seems impossible to complete unless the x and y values (sub components) are referenced separately, as in the suggested solution;
![image](https://user-images.githubusercontent.com/24306017/197471157-973a136a-07e6-4a28-89c2-18f8c77d0b55.png)

The first hint for this practice suggests as much (although the wording could perhaps be clearer what it was suggesting, given it was a new application of knowledge)
![image](https://user-images.githubusercontent.com/24306017/197471352-996b5af8-92d7-4325-9e71-e49ce327f060.png)

The problem is that, the way it is worded, it suggests this is because we are referencing Vector2 values but the previous Practice (20. Looping over arrays - Move Robot Along Path) ALSO had us use a for loop referencing Vector2 values in an array but we did NOT need to reference x and y values (sub components) separately.
![image](https://user-images.githubusercontent.com/24306017/197471986-c98aec37-7ecb-4435-a126-0e1f807cd44b.png)

As far as I can tell, there is no explanation as to why these two functions need to be treated differently. I assume it's because of the way the that draw_rectangle() and move_to() are written but since we can't actually SEE those, it seems to be teaching that sometimes you need to and sometimes you don't and it's just sort of a mystery as to which will work.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.