Help | Sololearn: Learn to code for FREE!
Новый курс! Каждый программист должен знать генеративный ИИ!
Попробуйте бесплатный урок
+ 1


Why is the blue cube moving fast? And this is provided that the variable DX is equal to 1, which in the end should not speed up the blue cube so much

8th Apr 2021, 12:30 PM
Alexander Sokolov
Alexander Sokolov - avatar
5 ответов
+ 2
because you do not use the timestamp argument available in the callback function function passed in the requestAnimationFrame function call ^^ that's the minimum to handle how fast move anything animated by this way (you cannot expect any animation cross browser/device speed without handling this ;P)
8th Apr 2021, 11:48 PM
visph - avatar
+ 1
How many age to start this app
5th Jun 2021, 3:01 PM
Nikhil Choudhary
+ 1
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace SoloLearn { class Program { static void Main(string[] args) { int x = 89; Console.WriteLine(x); } } } Help me in c, sir. Try it yuor self
17th Oct 2022, 10:49 AM
Bobby Devarapu
Bobby Devarapu - avatar
0 here is the problem. the dx and dy is too high
17th Nov 2021, 4:37 PM
Jackson Jameson
Jackson Jameson - avatar
If the blue cube is moving fast despite the variable DX being equal to 1, there are likely other factors at play that are contributing to its speed. The variable DX alone, which presumably represents a change in position or velocity, may not be the sole determinant of the cube's speed. Some possible reasons for the blue cube's fast movement could be: Initial velocity: If the blue cube had an initial velocity or momentum in a specific direction, it could continue to move at a fast pace even with a small change in position (DX). The initial speed could be due to external forces, previous acceleration, or an initial push. Acceleration: If there is an acceleration acting on the cube, it can increase its speed over time. Acceleration refers to the rate of change of velocity, so even with a small change in position (DX), if the acceleration is significant, the cube's speed can increase rapidly. Time: The time factor plays a crucial role. If the blue cube has been moving for a long time, even small changes in position (DX) can accumulate over time, resulting in a noticeable increase in speed. External forces: It's possible that external forces like gravity, friction, or other interactions are influencing the cube's movement, causing it to move faster than expected. These forces can affect the cube's acceleration and speed.
8th May 2023, 8:27 AM
Susan Braun