DEV Community

Erik Guzman
Erik Guzman

Posted on • Updated on • Originally published at notion.so

Stream 11/3/2019 - Github Actions and Reversing Gravity

Check Out the Stream @ https://twitch.tv/talk2megooseman

Had a great and fun stream today! Started it off fixing my Github Action and then learning about the new caching feature in Github Actions so dont have to re-install packages. After knocking that stuff I next started the adventure of doing reverse gravity command.

Today Objective

  • [x] Want go stuff from the past week
  • [x] What to call today's log
  • [x] Review last streams TODOs
  • [x] Fix an issue Github Action failing to yarn install because of a permissions error
  • [x] Make sure we deploy latest code for twitch-interactive-overlay
  • [x] Work on more items on the Projects Board https://github.com/talk2MeGooseman/twitch-interactive-overlay/projects/1
    • [ ] Working on a reverse gravity command

Notes

            steps:
                - uses: actions/checkout@master
                - name: Cache node modules
                  uses: actions/cache@preview
                  with:
                    path: node_modules
                    key: ${{ runner.os }}-node-${{ hashFiles('**/yarn.lock') }}
                    restore-keys: |
                      ${{ runner.os }}-node-

                - name: yarn install
                  if: steps.cache.outputs.cache-hit != 'true'
                  run: |
                    yarn install
  • Reverse gravity command in Phaser.io
    • We can set the gravity via scene.physics.world.gravity.y = -400
    • Need to update the math for our sprite animations and position because its assuming a positive gravity so all the commands will look just wrong
    • Tweak the logic in the UserSprite to changes the Y velocities if the gravity is flipped. But the same logic has to be spread to the other sprites the spawn on the screen. So decided to finally make a base class to have some base logic instead of just defaulting to user helper module.
    • Will need to finish doing the refactoring and switch the various sprite classes to use the new BaseSprite class

Shoutouts and Thanks

  • Lannonbr
  • indifferentghost
    • 6 month Resub
  • iScreemCodes
    • 3 months Twitch Prime Resub
  • cmgriffing
    • Raid of 18
  • theMichaelJolley
    • Raid of 44

Future action items

  • [ ] Finish the BaseSprite refactoring

Top comments (0)