Code edit (10 edits merged)
Please save this source code
User prompt
make the horizontal axis movement fluid, you should implement a smooth interpolation or easing function that gradually adjusts the axis position over time.
Code edit (9 edits merged)
Please save this source code
User prompt
when creating a new segment, set the properties - stockValue1 : the stock value of the start of the segment - stockValue2 : the stock value of the end of the segment - x1 : the x value of the start of the segment - y1 : the y value of the start of the segment - x2 : the x value of the end of the segment - y2 : the y value of the end of the segment
User prompt
set those values in drawSegment function
User prompt
in GraphSegment add properties : - stockValue1 : the stock value of the start of the segment - stockValue2 : the stock value of the end of the segment - x1 : the x value of the start of the segment - y1 : the y value of the start of the segment - x2 : the x value of the end of the segment - y2 : the y value of the end of the segment
User prompt
remove the yValue of the GraphSegment
Code edit (1 edits merged)
Please save this source code
Code edit (1 edits merged)
Please save this source code
User prompt
implement setDebugValues() by re-setting stockValuesHistory values by repeating 10 times the serie 50, 75 , 100, 125, 150 , 125, 100, 75 , 50
Code edit (1 edits merged)
Please save this source code
Code edit (19 edits merged)
Please save this source code
User prompt
periodically update vsaText
User prompt
Fix Bug: 'Uncaught TypeError: Cannot read properties of undefined (reading 'toFixed')' in or related to this line: 'var vsaText = new Text2('VSA: ' + verticalSlideAmount.toFixed(0), {' Line Number: 164
User prompt
add a text at the top left corner with the verticalSlideAmount without decimals labeled VSA
Code edit (1 edits merged)
Please save this source code
Code edit (1 edits merged)
Please save this source code
User prompt
in axis vertical movement and console log should be treated only for horizontal axis
User prompt
add a propery in Axis to differenciate horizontal and vertical
User prompt
remove the decimals in the log in axis updateSlide
User prompt
in horizontal Axis updateSlide, console log current stock value, and self.y
User prompt
Fix Bug: 'ReferenceError: upperLimit is not defined' in or related to this line: 'if (self.y <= upperLimit || self.y >= lowerLimit) {' Line Number: 28
User prompt
in the horizontalAxis'updateSlide function, add the requested condition to set moveSegmentsVertically to false
Code edit (1 edits merged)
Please save this source code
User prompt
the vertical movement speed is far too high
===================================================================
--- original.js
+++ change.js
@@ -2,8 +2,14 @@
* Classes
****/
var GraphSegment = Container.expand(function () {
var self = Container.call(this);
+ self.stockValue1 = 0;
+ self.stockValue2 = 0;
+ self.x1 = 0;
+ self.y1 = 0;
+ self.x2 = 0;
+ self.y2 = 0;
self.updateSlide = function () {
if (moveSegments) {
self.x -= slideAmount;
}
A Technical dark background. Nothing just a gradiant of colors from black to dark blue. Theme : stock market. background
A modern clean empty rectangular button without borders. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
without shadow
a basic empty ui popup with a black background. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.