• Bo

Piggy Payback! The Mechanics Are Here!

Welcome back to our Piggy Payback! devblog. We have a couple new mechanics to introduce to you today and more, so we really hope you enjoy the read!

To start off this week, we got some SFX and music and added them to the win and lose screens. On the win screen there is a short, happy/triumphant song over a positive chime and an applause SFX. On the loose screen there is a short sad trumpet song and we have a bunch of bird laugh sounds that play once randomly each time the lose screen appears. Similar to that dastardly dog from Duck Hunt!

We’ve added another brand new mechanic to the game. Well, a combination of two mechanics that work together. We created a breakable brick blueprint and a moving platform blueprint, both of which add an impulse to the pig upon hit. The idea is that you try to his the layers of bricks with your pig to break through them to get to the collectibles and points on the other side. The bricks disappear when hit by the pig and make a ‘brick crush’ sound. We also plan to add a brick crumbling particle system that plays when you break a brick.

In the construction scrips, we set up an editable variable for each of the 3 types of bricks. There are 3 different brick meshes, one for the bottom with no grout on the bottom, one for the top with none on the top, and one for any bricks in the middle, no matter how many middle layers, with no grout on the top or bottom. We can set the type of brick it is in the details panel.

We fixed the Add Impulse logic on BP_BreakableBricks and BP_MovingPlatform_Impulse. We used a break hit result node coming off the on component hit node for the static mesh. Then connected a "Mirror vector by normal" node with a get impulse direction node and from that, Set the impulse direction. We then multiplied it by 1000 and fed it into the Impulse pin of the Add Impulse node. Now it sends an impulse in the right direction every time, no matter what angle it hit them at.

The moving platform moves back and forth (left/right) across the level. The player hopes to bounce their pig off the bricks and then off the platform so it launches the pig back into the bricks. The moving platform, in combination with the bricks is very similar to those brick breaker/breakout games. But the levels will also have collectibles and other mechanics in them so its more complex than the brick breaker games. Right now we have a placeholder mesh in for the platform, and we’re currently in talks with how it should look for the final game.

We created the beginning of a button deck in the project. A base with 3 buttons that the player has to hit with their pig. When the pig hits a button, it depresses and lights up. Each button, when pressed, has a letter that lights up above it. The current button deck spells "P-I-G" when all buttons are pressed, but we will have other words as well. Once all the buttons are pressed it will either unlock something or give the player a points bonus or a points multiplier that's applied to future points gained in that level.

We fixed the problem with the moving birds. We had the lerp node going into the SetWorldLocation node as such:

A pin: CurrentZ (Location on the Z axis)

B pin: Travel Distance (How far we want it to move)

Alpha pin: From the timeline

The bird was going down really far, even with a travel distance of 10. We realized the B pin was wrong. We then put CurrentZ + Travel Distance into the B pin and it worked. Now the bird travels up and down exactly how we want.

We had the rotating block pieces made. The Triangle, square or hexagon that's in a level, which the player has to time their shots and bounce their pig off of at the right angle to get into hard-to-reach places. The final models and textures are done and they look great. That red rubberized layer on the outside, like the paddles makes you want to hit it with your pig.

Since the pig snout (pinball style) bumpers will be used in many different ways on many different levels, we decided to set them up so we can change the size of the bumper mesh and the impulse value of each instance individually in the details panel. We will probably be doing this to a lot of the mechanics since we plan to reuse them many times, but in all different ways for some very interesting puzzles.

Join Our Discord: https://discord.gg/vdF4ubqV4z

Site: DangerousMindGames.com

YouTube: https://youtu.be/PmY1aFAdUSs

#PiggyPayback #Piggy #Payback #Ricochet #Pinball #AngryBirds #Mrricochet #Shooter #Casual #CasualShooter #Puzzle #SpacialPuzzle #Spacial #Fun

#Addictive #Silly #Goofy #Cartoon