Welcome,
Guest
. Please
login
or
register
. Did you miss your
activation email?
French forum
Home
Help
Search
Login
Register
SFML community forums
»
General
»
SFML projects
»
My Megaman 2 SFML Project *video link fixed*
Print
Pages: [
1
]
Author
Topic: My Megaman 2 SFML Project *video link fixed* (Read 4171 times)
0 Members and 1 Guest are viewing this topic.
Shane
Newbie
Posts: 7
My Megaman 2 SFML Project *video link fixed*
«
on:
December 01, 2017, 06:12:40 am »
I was playing Megaman on my NES and thought to myself, I bet I could make this. A few days go by and this is the result. You may notice at times the blocks and sprites have a red border with white dots. That's just me toggling on/off the collision detection box and hot points for testing.
«
Last Edit: December 01, 2017, 09:54:54 pm by Shane
»
Logged
G.
Hero Member
Posts: 1593
Re: My Megaman 2 SFML Project
«
Reply #1 on:
December 01, 2017, 06:12:37 pm »
"This video is unavailable."
Logged
Shane
Newbie
Posts: 7
Re: My Megaman 2 SFML Project
«
Reply #2 on:
December 01, 2017, 09:49:57 pm »
Oops. Forgot to publish the video after uploading to youtube.*Fixed*
Logged
eXpl0it3r
SFML Team
Hero Member
Posts: 11032
Re: My Megaman 2 SFML Project *video link fixed*
«
Reply #3 on:
December 01, 2017, 11:00:13 pm »
This is quite impressive.
So is everything written from scratch?
Did you use some documentation on how megaman works (physics, scrolling, animation, collision, etc) or did you write everything "by eye"?
Logged
Official FAQ:
https://www.sfml-dev.org/faq.php
Official Discord Server:
https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog:
https://duerrenberger.dev/blog/
Shane
Newbie
Posts: 7
Re: My Megaman 2 SFML Project *video link fixed*
«
Reply #4 on:
December 02, 2017, 01:45:09 am »
Everything is from scratch. No physics engine no extra libraries, just SFML, C++ and photoshop.
I did alot of research of how games were programmed for consoles using the M6502 chip.
Collision Detection
The hardest part was the collision detection. I kept finding articles regarding 3D collision detection and other over complicated methods. I finally pieced together how AABB collision detection was done by assigning points on each sprite checking and solving one axis at a time for each point against a tilemap. I use full rectangles as bounding boxes for sprite to sprite detection. Once I had that working everything started coming together.
Animation
Honestly didnt do much research in this department. Just drew it out on paper (yes actual paper .. use it alot when i'm programming) and made a system that worked for me.
Tilemap & Scrolling
I started dabbling with Tilemaps and scrolling along time ago..One of my first tilemaps with scrolling i made to mimic the early ultima games. Those only scrolled by a complete tile each step. The megaman tilemap i made scrolls by one pixel at a time. BTW sf:views makes this SOOO much easier! many many iterations later i've got it down to a science.
Physics
This I just eye-balled until it looked right. I had an emulator open beside my Visual Studio all the time counting pixels and time to get an estimate for values to use.
Here is an example of an earlier tile engine i made with SFML. The animation needs some work. OBS also makes the scrolling choppy when played back. It's actually smooth as butter :p
Logged
G.
Hero Member
Posts: 1593
Re: My Megaman 2 SFML Project *video link fixed*
«
Reply #5 on:
December 02, 2017, 10:20:55 pm »
Looks great, like the real one. ^^
(though it seems like you sometimes jump higher than normally possible)
Logged
Shane
Newbie
Posts: 7
Re: My Megaman 2 SFML Project *video link fixed*
«
Reply #6 on:
December 03, 2017, 05:39:35 am »
Thanks. Fixed the jump it was an issue with the deltatime between frames.
Logged
Print
Pages: [
1
]
SFML community forums
»
General
»
SFML projects
»
My Megaman 2 SFML Project *video link fixed*