Discuss Scratch

TheEpikGamer211
Scratcher
1000+ posts

move () steps and change x by () are the same thing, one has to go.

so you know how
move () steps
is similar to
change x by ()
they are almost doing the same function, so why not remove change x/y by blank.

Last edited by TheEpikGamer211 (March 1, 2024 19:58:53)

Catscratcher07
Scratcher
1000+ posts

move () steps and change x by () are the same thing, one has to go.

move steps moves in the direction the sprite it is currently facing, move x/y moves straight in their respective axes, do you want to have
 
set [stored direction v] to (direction)
point in direction (90 v)
move (...) steps
point in direction ((stored direction))
every time you need to move in the x axis?
yadayadayadagoodbye
Scratcher
1000+ posts

move () steps and change x by () are the same thing, one has to go.

they're not the same thing, move () steps actually uses trigonometry to move the sprite in the direction they face.
Contraery
Scratcher
100+ posts

move () steps and change x by () are the same thing, one has to go.

They are far from the same - The move steps block accounts for the direction of the sprite:
https://github.com/scratchfoundation/scratch-vm/blob/74b9b4115e34b4a2ff8145950e4c8d9a13e4d3a1/src/blocks/scratch3_motion.js#L64
While the change x block doesn't whatsoever:
https://github.com/scratchfoundation/scratch-vm/blob/74b9b4115e34b4a2ff8145950e4c8d9a13e4d3a1/src/blocks/scratch3_motion.js#L246

Neither of them have to go as they both have their better use-cases.
EDIT: Ninja'd, partially.

Last edited by Contraery (March 1, 2024 20:14:52)

Malicondi
Scratcher
1000+ posts

move () steps and change x by () are the same thing, one has to go.

they're nowhere near similar move block works like this:
change x by ([cos v] of (direction))
change y by ([sin v] of (direction))
and the change x block simply changes in a fixed direction. This would make it a whole lot more confusing for newer scratchers, and also they have completely different functions
MagentaDude1359
Scratcher
100+ posts

move () steps and change x by () are the same thing, one has to go.

as already stated, they are the same thing. no support.
DangerPuppy10
Scratcher
1000+ posts

move () steps and change x by () are the same thing, one has to go.

MagentaDude1359 wrote:

as already stated, they are the same thing. no support.
They aren't the same thing. As stated above they are different
TheEpikGamer211
Scratcher
1000+ posts

move () steps and change x by () are the same thing, one has to go.

MagentaDude1359 wrote:

as already stated, they are the same thing. no support.
i said they are the same thing, so yeah, thats why i suggested to get rid of one of them
Contraery
Scratcher
100+ posts

move () steps and change x by () are the same thing, one has to go.

TheEpikGamer211 wrote:

(#8)
i said they are the same thing, so yeah, thats why i suggested to get rid of one of them
they arent, source code reveals that:

Contraery wrote:

(#4)
They are far from the same - The move steps block accounts for the direction of the sprite:
https://github.com/scratchfoundation/scratch-vm/blob/74b9b4115e34b4a2ff8145950e4c8d9a13e4d3a1/src/blocks/scratch3_motion.js#L64
While the change x block doesn't whatsoever:
https://github.com/scratchfoundation/scratch-vm/blob/74b9b4115e34b4a2ff8145950e4c8d9a13e4d3a1/src/blocks/scratch3_motion.js#L246

Neither of them have to go as they both have their better use-cases.
EDIT: Ninja'd, partially.
RethinkingVoxels
Scratcher
1000+ posts

move () steps and change x by () are the same thing, one has to go.

move () steps
is not the same as
change x by ()
.
Reporting to be closed
medians
Scratcher
1000+ posts

move () steps and change x by () are the same thing, one has to go.

TheEpikGamer211 wrote:

MagentaDude1359 wrote:

as already stated, they are the same thing. no support.
i said they are the same thing, so yeah, thats why i suggested to get rid of one of them
That person definitely meant not, first of all, if you look at earlier posts in the topic, people stated it wasn't the same, and second of all: why would that person say that just to say no support??
Also, it hasn't been the same thing:
Move steps with up direction:
Moves up/down (positive - up, negative - down)

Change x with up direction:
Moves right/left (positive - right, negative-left)

Tips Window:
Move steps:
States it moves based on direction

Change x:
States that positive numbers go to the right and negative numbers go to the left

I'm not sure if this is in 3.0, but the point in direction block in Scratch 2.0 has a dropdown for different directions too:

Last edited by medians (March 2, 2024 02:28:46)

Powered by DjangoBB