Google Classroom
GeoGebraGeoGebra Classroom

How to add onboarding to an applet

You can add onboarding similar to that shown above by following the steps below. Assumption: you have a point P defined somewhere in your applet. Also note that you can pulse objects other than points using a similar technique: you just need to create a tool to generate the specific type of pulsing object that you want. Steps:
  1. Load the tool circlePixels which you will find in the applet above. This will allow you to create a circle with a given pixel size, and a given pulsing size in pixels.
  2. Define the following objects:
    • onboarding = false
    • pulsingSpeed = 8
    • pulsing = 1
      • Interval setting: Min = 0, Max = 1, Increment = 0.1
      • Animation setting: Speed = pulsingSpeed, Repeat = Increasing
  3. Add the following code to your reset button: SetValue(onboarding, true) StartAnimation(pulsing, true)
  4. Create a pulsing object using the circlePixels tool: pulsingPoint = circlePixels(P, 7 + pulsing * 7, Corner(1), Corner(3), Corner(5)) with parameters being (<your point>,<size of your point + pulsing * size of pulsing> ,...) and the following settings:
    • Color = same color as P
    • Dynamic opacity = 1 - pulsing
    • Line thickness = 0
    • Line opacity = 0
    • Show label = false
    • Selection allowed = false
    • Condition to show object = onboarding
  5. Add the following code to the onUpdate script of point P: SetValue(onboarding, false) StartAnimation(pulsing, false)