Navigation

    Fuze Arena Logo
    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Popular
    • Users
    • Groups
    • Help
    • Discord

    2d skateboard game

    Beginners
    18
    149
    20186
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • waldron
      waldron F @waldron last edited by waldron

      @waldron said in 2d skateboard game:

      @Spacemario i'l upload a video later altho a cool down does sound like a possible fix just don't know how i would code it,
      my code from memory atm is kinda like

      if c.y state = trick then
      playerY movespeed -= // gives me the drag effect (slowdown)
      playercoin += 1            // gives me the score 
      .........so on so on 
      

      Tony hawks gets round this issue with balance bars

      f71514a8-8118-416b-9459-c0c384138b45-image.png

      1 Reply Last reply Reply Quote 1
      • waldron
        waldron F last edited by

        1 Reply Last reply Reply Quote 4
        • waldron
          waldron F last edited by

          level is getting rather large now think im at 350 columns in length, really want to start introducing moving platforms i thought i could use the data from my enemy's and modify it but still proving to be a problem with my ability to code.and help would be greatly appreciated

          1 Reply Last reply Reply Quote 0
          • Martin
            Martin Fuze Team last edited by

            I would have thought moving platforms would pretty much be enemies too. But instead of dying when you collide with the top of the sprite you just land on it. Maybe a little more complicated in that you need to detect just the top of the sprite(s), not the bottom or sides but beyond that I don't see a lot of difference.

            waldron 1 Reply Last reply Reply Quote 0
            • waldron
              waldron F @Martin last edited by Martin

              @Martin il keep tinkering with the code, i got rid of the gravity so i have it floating and moving as of now
              using this

                   if enemies[i].state != death then
                      enemies[i].velocity += gravity
                      if !collision( x + eSize.x / 2, y + eSize.y + enemies[i].velocity / eSize.y ) then
                          enemies[i].y += enemies[i].velocity / tSize
                      else
                          enemies[i].y = int( ( enemies[i].y + enemies[i].velocity / tSize + eSize.y / tSize ) ) - eSize.y / tSize
                          enemies[i].velocity = 0
                      endif
                      if playerX + pSize.x > x and playerX < x + eSize.x and
                          playerY + pSize.y > y and playerY < y + eSize.y and
                          enemies[i].state == active and velocity > 0
                      then
                          enemies[i].state = death
                      endif
                  endif
              
              1 Reply Last reply Reply Quote 0
              • waldron
                waldron F last edited by

                wanting to rebuild my game using the level editor but having problems with the sprite camera following the player

                1 Reply Last reply Reply Quote 0
                • Martin
                  Martin Fuze Team last edited by

                  Does centreSpriteCamera(player.x, player.y) not cut it ?

                  waldron 1 Reply Last reply Reply Quote 0
                  • waldron
                    waldron F @Martin last edited by

                    @Martin il test later that should do it, for another game im working on how would i manage the camera scrolling screen by screen

                    1 Reply Last reply Reply Quote 0
                    • Martin
                      Martin Fuze Team last edited by

                      if it's a constant rate or similar then just track the X/Y co-ordinates, updating them frame by frame and then supply them just the same? I might need to better understand what you want to do...

                      waldron 1 Reply Last reply Reply Quote 0
                      • waldron
                        waldron F @Martin last edited by

                        @Martin the screen by screen, is for my prince of persia remake just dont know how to track the player character on the level editor with the camera been busy doing the sprite sheet stuff but will be loading into a test map soon and il share about quarter the way through with the sprite sheet :)

                        1 Reply Last reply Reply Quote 0
                        • waldron
                          waldron F last edited by

                          Time to revisit this,brand new map level and skater sprite, now i'm using maps how does items translate from the way i'v done it before using the level array.
                          or is it just the same but instead of col and row is it just a matter of plotting the items to the screen?

                          Dave 1 Reply Last reply Reply Quote 1
                          • Dave
                            Dave Fuze Team @waldron last edited by

                            @waldron There is a feature in the Map Editor update called marked locations (not the same as marked areas) - it allows you to place a flag on a location in your map and give it a name. These can be accessed with getMapLocation( locationName ) to return the coordinates needed to place the items.

                            waldron 1 Reply Last reply Reply Quote 2
                            • waldron
                              waldron F @Dave last edited by

                              @Dave il have a gander later no doubt i will give you a shout if i get lost
                              thanks man

                              Dave 1 Reply Last reply Reply Quote 1
                              • Dave
                                Dave Fuze Team @waldron last edited by

                                @waldron No worries mate I'll be here!

                                1 Reply Last reply Reply Quote 0
                                • waldron
                                  waldron F last edited by

                                  Skater kid ext%eme, got the rolling animation done :)

                                  1 Reply Last reply Reply Quote 6
                                  • spikey
                                    spikey F last edited by

                                    Very cool. Very fluent animation, decent shadow effect.

                                    1 Reply Last reply Reply Quote 1
                                    • waldron
                                      waldron F last edited by

                                      Will add in acceleration, ollie and fall/wipeout animation tonight, was thinking of adding in a brace button which you need to press to land

                                      1 Reply Last reply Reply Quote 1
                                      • Dave
                                        Dave Fuze Team last edited by

                                        Always just blown away by your skill.

                                        waldron 1 Reply Last reply Reply Quote 1
                                        • waldron
                                          waldron F @Dave last edited by

                                          @Dave 95% patience lol I just love creating stuff on fuze

                                          1 Reply Last reply Reply Quote 1
                                          • waldron
                                            waldron F last edited by

                                            Level assets

                                            Dave 1 Reply Last reply Reply Quote 4
                                            • First post
                                              Last post