Comments (2)
Thanks for taking the time to give feedback. In this case, the lesson's correct. To move to the end of a grid of 5 cells, if you're on cell 1, you need to move 4 times. range(5) (the size of the array) would produce 5 numbers (0, 1, 2, 3, 4) and make you move 5 steps, so 1 cell past the limit. That's why you need to subtract 1 from the board size.
I'm changing the issue title to add a new sentence about that to the lesson.
from learn-gdscript.
if you're on cell 1
I'm guessing cell 1 refers to the 0
on y
in Vector2
? My apologies for the oversight. I assumed there was a "cell 0" and forgot that it was just an index.
Is it correct to presume that we can use range(board_size.x)
if the robot is not already on the board?
from learn-gdscript.
Related Issues (20)
- 20. Strings Lesson 2 Issue with different variable names.
- gdscript
- [Very Minor Correction] Period goes on next line on Lesson 4 - Drawing a Rectangle
- Broken links on completion page HOT 2
- Lesson 20 - Excercise 2, right answer with wrong script
- "Lesson 23 - Excercise 2: Realign the train tracks" problem to understand task
- [Lesson 14. Multiplying Part 1 Practice] Incorrect math calculation regarding max_health value, appears to level up twice when my code only asks it to level up once
- script with str function call fails
- Lesson 18 creating arrays should say 'unroll' not 'unwrap'
- Lesson 25, inconsistency between add_unit example call arguments and practice exercise place_unit function
- lesson 23 practice " Using right items" task is a unclear and may be teaching bad habits or hardcoding values HOT 2
- Lesson 27, practice 2 doesn't actually differentiate between ints and floats HOT 1
- Lesson 17 - "Moving to The end of the board" suggestion
- Lesson 7 Practice 2
- Creating a parameter list with undefined parameters messes with my brain
- Lesson 17 misspelled word
- Lesson 1: Turkish translation is missing
- Lesson 3 HOT 2
- Lesson 15: Excersise 1: Increasing scale using Vectors HOT 1
- Keyboard issue HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from learn-gdscript.