playMaker

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Thore

Pages: [1] 2 3 ... 32
1
General Discussion / Re: I need some help
« on: April 12, 2021, 04:56:14 AM »
Second problem i want to add footsteps into the game, everytime the player walks the footsteps sound is added, how do i do that.

In the animation timeline, add animation events where the foot touches the ground.
https://docs.unity3d.com/Manual/script-AnimationWindowEvent.html

Then, in the list, select PlayMaker's SendEvent and provide the name of a global event in playmaker that you want triggered at that animation frame. In the PlayMaker state, add the foot's sound.

2
PlayMaker Help / Re: Mario Galaxy like gravity 2d asset
« on: March 05, 2021, 06:48:49 PM »
My guess is that your Mario detects the closest of such a circle, shoot a ray in that direction and use that to turn Mario towards it. The basic principle could be taken from a tank / turret example. Then, you’d also apply forces towards that circle ground. There’s a long way to go still, but a starting point.

3
PlayMaker Help / Re: Walking on Slopes
« on: January 18, 2021, 08:09:19 AM »
Unfortunately, when I adjust those 2 settings, it impacts the way he jumps. I would like to be able to not slide on slopes while not affecting his movement and jumping abilities. Any other suggestions? Thanks!

That's why you have a state machine. :D In the jump state, you apply one type of setting and when on the ground, another type of setting, and when on a slope a third way and so on.

Also, once I get that figured out, I have one other question. When my player walks on a slope, he does not account for the slope; he is still facing upright. How do I get him to walk at an angle with the slope? Hope that makes sense. Thanks again!

Fairly complicated to do. A few pointers: disable the freeze constraints in the rigidbody, then make a mechanic to align the character in specific states. You have to shoot a ray down, determine the angle, then rotate the vector up towards the normal direction from the ray. Maybe there is a tank turret example somewhere that shows how to rotate towards.

If this isn't essential, and you are beginner, I'd recommend to do tackle other things first and worry about slopes much later. You can also "hide" the problem by making the ground tilted forward or the view angle seem a bit from above, rather than straight on.


4
PlayMaker Help / Re: Walking on Slopes
« on: January 15, 2021, 08:45:34 AM »
You can try one or several of these:
— change the physics material on the character, set friction to 1
— reduce gravity scale


5
PlayMaker Help / Re: Walking on Slopes
« on: January 14, 2021, 10:36:17 PM »
It’s a Unity, or generally, a physics thing.

The proper solution, where the speed is maintained on slopes is advanced even in script, and having moved on from Playmaker, I do not know if actions exist to make it. You would shoot a ray down onto the slope, get the normal, use the vector perpendicular function to get the perpendicular angle (i.e. the angle to move) and set velocity in that direction.

However, the “proper” solution is often not needed or even wanted. If you just want to climb slopes at some lower speed, you detect the slope and get the normal, run through vector angle to get the angle, and if it exceeds some value, tweak gravityscale, drag and your velocity/force while on the slope.

6
PlayMaker Help / Re: 2D player knockback (when hit by an enemy)
« on: November 10, 2020, 06:32:58 PM »
Direction * -1 will flip the direction.

7
PlayMaker Help / Re: Colliders / Triggers driving me INSANE!
« on: October 12, 2020, 04:01:49 AM »
To keep them separate, the different types of collisions should be on different game objects. They can also be parented, which makes no difference. Now that the colliders are differentiated, you also need to give them different logic.

To do this you can use the tag and layermask to efficiently detect relevant stuff. Once you detect an object, you could read any property from it, like the existence of a component, values inside its FSM and so on.

Under project settings and physics, somewhere, you can also tweak the collision matrix.

If your game has a lot of objects coming to the ship, also potentially simultaneously, you need a more robust solution that can keep multiple detections in an array and then loop through them for relevant information.

8
PlayMaker Help / Re: PS4 controller mapping
« on: September 28, 2020, 10:51:57 AM »
In general:

(1) set up a binding composite vector2 in the input asset.
(2) click on path > listen and fetch Left Stick / Up [Gamepad], with composite part > up.
(3) repeat step 2 for all directions.

There is also Left Stick PS4 in particular, but I use the more general Gamepad with my PS4 controller and that works great (though I don't use PlayMaker for this, but script).

Then, the actions should have one to get a composite vector2. The beauty of this new system is that the "code" side doesn't care what exactly triggers the input action, or where the vector2 comes from.

9
User Showcase / Re: Finished Projects Made With PlayMaker
« on: September 28, 2020, 08:23:29 AM »
I made a game that makes weird animations that uses Playmaker a lot

Trailer
Its called "Nightmare Puppeteer" and now available on Steam https://store.steampowered.com/app/1355310/Nightmare_Puppeteer/

I used Playmaker for all the state management.... if anyone is interested in learning about how I used Playmaker in it let me know and I'll do a little breakdown. Thanks.

welcome back, I’d be interested in that!

10
PlayMaker Help / Re: PS4 controller mapping
« on: September 27, 2020, 06:58:50 PM »
Use the new input system. For the setup, see here.


Then use these actions to interact with it:
https://hutonggames.com/playmakerforum/index.php?topic=21797.msg95729#msg95729

11
PlayMaker Help / Re: 2d Parallax Background
« on: September 27, 2020, 04:43:54 AM »
Don’t reinvent the wheel there ;) I would grab a script that does this, which should be dime a dozen, unless there is really some special feature; or you want to learn how to do it.

12
Share New Actions / Re: Unity Input System [In Preview] Actions
« on: September 21, 2020, 02:53:02 PM »
You should be able to return analog values, too, by going into the input asset (where you set everything up) and inspect the options under the vector2 binding.

13
PlayMaker Help / Re: Among us CCTV camera ?
« on: September 18, 2020, 07:13:32 PM »
You can render cameras to textures, here‘s an example I found on the quick.
http://unity.grogansoft.com/in-game-security-camera-using-render-texture/

14
PlayMaker Help / Re: Need help with damage
« on: September 13, 2020, 12:24:07 PM »
I can’t remember which around it was: Set Event Info is setting things into a package of sorts, and then Get Event Data can read that event. Search the forum or ecosystem as there should be an example somewhere.

15
PlayMaker Help / Re: Remembering object in a prefab
« on: September 13, 2020, 11:16:21 AM »
In Unity, prefabs can’t keep reference with scene objects, only within their own local hierarchy. To create the reference (“remembering”) at runtime, you need to find that object with some other means. The easy but potentially less robust solution is finding by tag (or name, but avoid using name, because you might rename later). Finding by tag is perfectly fine, but not ideal if this issue comes up thousands of times.

The more elaborate and robust solutions are the domain of controllers or managers, two different styles to manage objects. These are dedicated objects that keep track of objects and references.

Pages: [1] 2 3 ... 32