You can now create an swinging blade obstacle that requires a single joint fixture. With this in hand you can create many more single joint objects.
- [Instructor] We can also make more complex…obstacles that move.…We do this in the GameMaker Physics Engine…by utilizing joints.…For this obstacle, we're going to use the revolute joint.…The revolute joint allows one physics fixture…to revolve around another at a location that we specify.…Let's use it to create a simple swinging blade obstacle.…Let's take a look at the sprites that we'll use.…I'll open up the Sprites folder,…go to Obstacles,…and let's check out the s_swing_blade sprite.…We can see here I've set the origin for the sprite…to be at the top center…at x equals 67 and y equals zero.…
This is the location where we'll create the joint.…Let's head down to our Obstacles folder in Objects.…Right click and say Create Group.…I'll call it Swing Blade,…and let's Create an Object.…I'll call it o_swing_blade.…In the Sprites, we'll go to Obstacles…and select our swing blade,…and check Uses Physics.…Let's first set our Collision Shape.…I'll choose Box.…
I'll click Modify Collision Shape.…Center the window.…And let's adjust the physics shape…
- Setting up basic game components
- Creating the player object
- Using Finite State Machines
- Making the player duck
- Creating physics fixtures in code
- Creating physics obstacles
- Box2D liquid physics
- Creating particles that behave like water
- Creating a floating blocks obstacle
- Creating a swinging chain obstacle and a rope bridge
- Adding the finishing touches
Skill Level Beginner
1. Set Up Basic Game Components
2. The Player Object
3. Create Physics Obstacles
4. Liquid Physics
5. Decorate the Level
6. Finishing Touches
Next steps1m 2s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.