Playmaker Forum
PlayMaker Help & Tips => PlayMaker Tutorials => Topic started by: cloud03 on December 03, 2013, 07:31:29 PM
-
[UPDATE, 05/16/2014] New Episodes for the 2.5D Series, which is part 9 cover Deploying onto Android Device.
Hi guys, I've just uploaded a physics based platform setup tutorial purely using playmaker, here is the link:
Part 1 - Basic Movement:
Part 2 - Moving Platform:
Part 3 - Ledge Grab and Climb:
Part 4 - Converting to Mecanim:
Part 4a - Mecanim Tweaks:
Part 5 - Rope Swing:
Part 6 - Ladder System:
Part 7 - Weapon System:
Part 8 - Adding Enemy:
Part 9 - Android Deployment:
2D Sprite Based Platformer:
Part 1 - Basic Movement
Part 2 - One Way and Moving Platform
PS:English is not my native language, so please excuse if there any part that are unclear, you can just comment and I will reply ASAP, or maybe discuss it here...
-
Hi,
This is very much welcomed!! thanks for this.
It would be good you share the project too, that will help people relate to what you are saying and see it in unity as well, it's very important. Also so that they can compare with their own attempt later, and prevent the typical ( it doesn't work, tho I did exactly like how you said :) )
Bye,
Jean
-
thanks for the feedback jean...
I've sent you a PM regarding sharing the project files, could you check it?
Thanks
-
updated, just added the 2nd part, which deals moving platform... :)
-
Hi,
can you bump me next week on this? thanks :)
bye,
Jean
-
Hi Jean, I've sent you a private message regarding your suggestion for sharing project files, could you check it? Thanks
-
Hi,
I have nothing in my pm inbox coming from Cloud03, can you send me your message again? thanks,
Bye,
Jean
-
I've sent it to your mail by mistake....please check it, thanks
-
Excellent, really helpful tutorials cloud03.
-
Hi,
yes, received. As far as packaging. You should not put the PlayMaker Folder at all iny our package, that will be the best approach.
So you should create a single top level folder with all your assets in there and package that folder only.
If in doubt simply send me packages and I'll validate them.
Bye,
Jean
-
I haven't had any real success with physics and characters before so have avoided that so far, so your tutorial is a good starting point. I have a question that may be better suited in the unity forums 'absolute 101', but anyways; why does my character, after having set up rigidbody and capsule collider with the getAxis+setVelocity, tip over on the capsule colider? pressing left or right will initially just tip him one way or the other on the capsule coliders axis until the bot is flat on the floor and then you can drag him either way lying down, what am I missing?
Edit: I had frozen the wrong axis ::)
-
Hahaha that is also happens to me when I first trying to create this...glad you got this sorted...
I'm in the middle of creating the next lesson on adding rope jump, and hang on the ledge, hopefully I can release it soon....
-
Hi guys, finally got the time to finish the third series of the tutorial, which covers ledge grabbing and climbing...so enjoy guys!
Feel free to ask if there is any part that are unclear..cheers
-
This is really great. I've been looking for this kind of tutorial, in the end you'll get a sorta finished game, type. All I've been getting are bits of tutorial that are not carried onto the next video. They are great but doesn't help a noob like me.. :p
Anyway, looking forward to the next part.
-
Hi Jean, I've sent you a private message regarding your suggestion for sharing project files, could you check it? Thanks
Is there any project files? Sorry, I don't see any, althought tutorial is self explanatory and very wll done, thanks for sharing your knowledge.
-
I've forget to upload the project files, just uploaded it now, and here is the link:
www.romifauzi.com/files/2DPhysicsPlatformerProjectFiles.unitypackage
Just import it to a new project with playmaker imported before (and the custom camera action I've included on the youtube video description)...
Glad to hear the tutorial is understand-able .. :)
-
Would be cool, if you could do this with mobile :)
-
It is quite fast actually in mobile, I have tested it, and with the current tutorial, you can simply change the input, by creating a GUI for controls, and make that GUI to change the horizontalAxis and verticalAxis variable accordingly, and then disable the get axis action....that should worked...
Hopefull I can do the tutorial how to make it mobile soon....
-
updated part 4th, which dealing with mecanim. cheers :)
-
Another update, please check the first thread... :)
-
Thank you very much! Your tutorials are really impressive and useful, very well done, exactly what I was searching for!
Do you think it would be possible to attach updated project files (with mecanim)?
-
Thanks a lot for the kind words...Guess I forgot to include the updated project package.., well here it is:
http://www.romifauzi.com/files/2DPhysicsPlatformerProjectFiles_mecanim.unitypackage
Hopefully it'll help :)
-
Thanks, this helps!
Looking forward for rope / ladder tutorial ;)
-
Bump, uploaded a new tutorial episode, basically for doing 2D Sprite Base Platformer, and I've decided to start from the beginning for this one to make it more simpler and clearer, and I've also do couple of things differently that is also applicable to the 2.5D one...
hope you all enjoy the tutorial, cheers! :)
-
Thanks a lot !!!
I'm waiting for this 2d sprite tutorial long time :).
Greetings
-
@darekk: thanks a lot
Uploaded a new episodes, please check the first post... :)
-
I think it would be much better if you explained more about why you do the things you do in your videos. Right now you mainly just show people what parameters to put and what actions to use and stuff, but you don't really explain much why and how it works. So basically I'm learning what to do, but not why and how it works. Just some constructive feedback for you. Other than that, your videos are great.
-
dzyothwrld: thanks a lot for the feedback, I'll keep that in mind on future tutorials. Cheers!
-
Update: New Episodes for the 2.5D Series, which is part 5 covers rope swing, check the first post....
-
Just uploaded a new episodes, covers how to make a Ladder System, please check out the first post!
-
Newb question icloud03, how would 2D gameplay work on pre-unity 4.3 versions? I ask this because, when I was experimenting with playmaker plus the standard character motor, and platform controller scripts that unity provides, a issue would be the Z axis is enabled and my character would just fall off of a level.
-
@coffeeANDsoda: do you mean 2D Gameplay with 3D objects pre 4.3? If its the case, I simply constraint the Z axis on rigidbody, and don't use the standard character motor, on these tutorials, I'm not using any standard script from unity, I build it with playmaker from scratch.
Or another way of doing it, if its not possible using constraint. Just add a invisible collider on each of the edge, and create a physics material, set the friction to 0 then assign the material to the invisible collider. This will make the character stay on the ground, and not fall off of a level.
-
Invisible collider IE a boxed collider?
-
yup, shape can be anything as long it is a collider, with no mesh renderer, so it is invisible and it will hold the character to stay on the ground
-
Right now, I'm having issues with other playmaker games that I am working on, so I'd like to dig into some of these 2.5D playmaker tutorials of yours to make a game using this type of perspective and reveal it.
-
Sure! let me know if its already available then, can't wait to see it :)
-
Isn't there a way to do animation without mecanim? Because I thought about using other means or just go with a static image for now.
-
You can use the legacy one, but you won't be able to use sprite animation, if it is a 2d game, and you use some sort of ik for the 2d character (with splitted body parts, and parented inside unity, then animated), you can use legacy animation, there is a thread regarding this.
But I'm all about mecanim right now, for me it is really good, and once you grasp the concept behind it, there is nothing you can not do literally with mecanim. For me there is no reason to not use mecanim, and I don't think I'm gonna go back with legacy again...Is there any difficulties for you with mecanim system?
-
I'd just like to know what other alternatives are out there.
-
Plus, I'd like to set up a jumping system by adding another FSM without parenting another object in order to make the player land naturally. Can't I add force on another state with a negative value of force, since if my character is going to jump, I'd have to use the Y axis.
-
What kind of jump do you want to achieve?
If you mean with parenting another object is the groundDetect, you can use raycast for ground detecting, that will eliminate the needs of a trigger object such as groundDetect.
Of course you can add "add force" to another state with negative value, I'm not sure though with what you are trying to achieve by this, could you elaborate more?
-
What kind of jump do you want to achieve?
A type of jump that applies for an area with normal gravity which includes 2 FSM's on one object(the player). Basically I want my character to jump normally.
-
Well, the jump part of the tutorial is actually quite normal, it is using unity physics, so gravity automatically takes into account.
-
Though it still acts like the player is jumping on the moon.
-
well in that case, you can increase the mass of the character, to make it heavier, so it will feel more realistic, just try fiddling the mass character, and the jump force to get the best feel you're looking for...
-
well in that case, you can increase the mass of the character, to make it heavier, so it will feel more realistic, just try fiddling the mass character, and the jump force to get the best feel you're looking for...
When I increase mass on my character it doesn't really jump. Isn't there an action that temporarily increases mass when the player lands?
-
well you can set the rigidbody property while on air, and change the mass value...but it would be simpler if you just adjust the add force for jumping value, the default amount is 250, so if you increase the mass of the character, you will also have to increase the jump force.....but the gravity will be the same, so by changing both of those value, you still can jump high or low, and fall or lands quickly because of the higher mass...
-
Just feel that when I set jump force, it's like no matter the amount, it doesn't feel as responsive as add force landing for forcing the player down. It's like theirs a delay or lag when the player jumps.
-
well in that case, you can modify the jump to tailor your needs, adding force while falling, or changing the mass temporarily while falling might be a solution.
-
How would rigidbody mass be modified though if I had to use an action in order to achieve that? I can't use a force mode besides force, then it acts like the player is launched like a rocket out of control.
-
under jump state, after user press jump button, and add force action executed, drag the rigidbody component to that state and choose set property instead of get property, change the rolldown menu properties to mass (or something about mass), and a float input should be available, and change it to any amount you want, please refer to a set property action regarding this.
-
Drag rigidbody component? So in add force, I would switch it to Specify Game Object?
-
the idea is changing the character rigidbody mass on runtime via playmaker states, and in order to do that, you'll have to use set property action. Set property action can modify any property from a component, for clearer explanation please refer to this tutorial:
-
I see. It's working a lot better now. More responsive, however, when I set up a few platform cubes up, when I fall off of them, it acts like it's floating around in the air until a press space. Isn't there a way to resolve this issue like detection without another object on the button of the player to check whether or not theirs anything to detect?
-
Well instead using a trigger object for detecting ground, you can use raycast, I've uploaded a video tutorial on how to do that, but instead using raycast 2d like in the video, use raycast (without 2d) for 3d objects. Check the video on the first page, the first part of 2D Sprite Platformer series..
-
Well instead using a trigger object for detecting ground, you can use raycast, I've uploaded a video tutorial on how to do that, but instead using raycast 2d like in the video, use raycast (without 2d) for 3d objects.
Did add the standard raycasting actions for the states, and added a ground tag to the platforms and ground. Still get the same results.
-
Can you send me your stripped down project? I'll take a look if you want...
-
This is what I have for the scene.
https://db.tt/2T854oY9 (https://db.tt/2T854oY9)
https://db.tt/NYv3jxfC
https://db.tt/8ldFBcYV
https://db.tt/ny2MLkTD
https://db.tt/wja8P6qg
https://db.tt/CuSsyPiP
https://db.tt/lcO7QMGc
https://db.tt/uKnyJZmw
https://db.tt/DUDJpaIb
-
Under raycast check, I think the wait action time is too long, perhaps set it to 0.1 or 0.2 should smooth things out...
-
Tried that, still get the same results. What about adding raycast and everything else to the first state?
-
Maybe that will do, put raycast after button jump pressed...
-
Maybe that will do, put raycast after button jump pressed...
Along with Set Game Object? Therefore the actions would work like following top to bottom?
1st: Get Button Down
2nd: Set Game Object
3rd: Raycast
4th: Game Object Compare Tag
I thought about this because actions act differently when you have position them in a different way.
-
Tried having the states like that in order and I still can't get raycast to work properly. Here's the project, even though it's bigger than it should be.
https://db.tt/g7wmqQQo
-
Well, after checking your scene, the most basic problems lies on your scene scale, your object scale relative to scene is very big, for example the 2d player has a 12 units scale on every axis, and the ground is also so big.
I'd change the scale for the sake of tidiness (scale everything back to one, and then scale the ground accordingly), but if its too much of a hassle, you can change the gravity value under physics setting (under project settings)...
here is the scene I've modified, just put it inside your asset folder, and then open it up, also change your gravity value, because that setting depends on the project, I've change it here, but yours may stay the same, so you'll have to do that also, I
ve set it to -250, and it is all good...
PS: I've created a new FSM for jumping, and disabled yours (but not deleted it)
-
PS: I've created a new FSM for jumping, and disabled yours (but not deleted it)
Would the scale of each object contribute to the player being unable to move around? Because I can't move my character.
-
It is working fine here on my end, one thing please make sure the variable for moving stored on get Axis, and set velocity, because it was reseted to none when I first imported your scene, so I have to set the horizontalAxis again....
-
Which for Get Axis? The global variable or local variable you made?
-
On your FSM, set the get axis variable again, it can be global or local, as long it stores the get axis variable, and then feed it back to set velocity action on the x axis...
-
What about deleting it and adding the action again? Because for some reason, it's not responding at all.
-
You can try that, it should be working though...
-
For set velocity, it wouldn't respond to input, but when I used that variable on the X axis option, it did work. However, gravity and the player getting stuck on tagged objects when pressing jump still remains a big issue. A day ago, I just used add force in the opposite direction, while it did help the moon gravity problem, still a big issue is getting stuck on other object it would collide with and the player having the option to jump again in air when you try to fall off of a platform.
-
I've uploaded the whole project in a clean new project, and setting it accordingly, here is the link:
https://www.sendspace.com/file/j4frmy
-
Does it work with the version of unity I'm using? I'm using 4.2.2 Because it saids it's not compatible and if I open it that it would risk data loss.
-
I'm using 4.3.4, so you will have to upgrade your Unity...
-
Is there anything in the project that would prevent it from running in my version? Or would that I would have to go through all my other projects and back them up somehow?
-
You can just try to open it on 4.2.2, if its not working, then upgrade the Unity.
I would also recommend to back any other project into a zip, so if something went wrong, you can extract it again from the zip files...
-
On your end, how do you feel about how jumping reacts? Because when I get to other platforms it doesn't feel as responsive as the first platform and even those objects are tagged.
-
On my end it feels fine for me, no difference on the jumping effects..
-
What about touching a end of a platform or side that's like a wall? Because when I do that when I fall off of one, when I press space, it stops or acts like it's stuck.
-
Plus, when I set up the FSM the way that you did for jumping it doesn't respond until I connected to the states that were like yours like 40 times. But when the raycast down state with a jump transition flowing into the Jump now state it has the low gravity affect. I think this isn't normal because I also recall that your projects FSM only gave the player the ability to jump once, and for some reason that isn't the case for mine.
In terms of how the players rigidbody is set up, since I made it a bit smaller then yours. It's set up this way.
The players scale on Transform is following.
X Y and Z = 1.8
Players rigidbody
Mass = 3.1
Drag = 0.14
Angular Drag = 0.45
-
for when the player is on the edge, the problem is the raycast only start from the middle point, so it doesn't hit the ground, you'll have to add another raycast from the edge of the bounding box of the player with direction also down to detect this, you can search tutorial regarding raycast for this issue.
As for your FSM not working, I'm not sure what causing it. I've set it once and it worked right away, so there is must be something wrong going on, can you check my tutorial again, see if you missed a step?
-
for when the player is on the edge, the problem is the raycast only start from the middle point, so it doesn't hit the ground, you'll have to add another raycast from the edge of the bounding box of the player with direction also down to detect this, you can search tutorial regarding raycast for this issue.
Don't understand. You added another raycast action in your modified version of my project? Don't think I spotted that unless you are talking about going back to your tutorial which did rely on a separate cube on the bottom of the character with another FSM. Like I said, I'm kind of confused because I am using the same actions as your project.
As for your FSM not working, I'm not sure what causing it. I've set it once and it worked right away, so there is must be something wrong going on, can you check my tutorial again, see if you missed a step?
If I'm not mistaken the project that you uploaded seems to differ from your tutorial series. I recall that you added a global variable as well as making a transition global on another FSM.
-
Don't understand. You added another raycast action in your modified version of my project? Don't think I spotted that unless you are talking about going back to your tutorial which did rely on a separate cube on the bottom of the character with another FSM. Like I said, I'm kind of confused because I am using the same actions as your project.
Nope, the one I've created indeed has a problem on the edge, and it is caused because on the edge, the raycast doesn't hit the ground, so to fix it, you'll have to add yourself another raycast but with a slight shifted origin on the x axis, so that one will still detect the ground when the player is on the edge, please refer to the 1st pic
If I'm not mistaken the project that you uploaded seems to differ from your tutorial series. I recall that you added a global variable as well as making a transition global on another FSM.
The basic system for the jumping is actually the same, the one in the tutorial and the project, the same theory applies, regarding global variable, I'm not quite sure what you meant with it? the one that using raycast does not need global variable at all to jump, local will do.
-
In the first part of the 2d sprite platform tutorial? I thought in Part 1 when you covered raycasting you made a transition(Do Jump, On Ground) global to work in two FSMs all at the same time.
-
Can you check it again:
I'm sorry I cannot help you further, cause I don't know what makes it doesn't work on your end, everything running fine here, although for the raycast on the edge you'll have to try adding yourself, but the concept just like the picture I've attached before...
-
I will take a second look at it. I could be mistaken with the first series of tutorial videos that you covered regarding a 2.5D environment instead of full 2D like you just posted above.
-
When I set up the movement the way that you do in your 2d sprite tutorial, along with just a rigidbody and capsule collider, the keys go in the opposite direction compared to what value of X is on both flipping states?
-
The flipping method are not meant for the 3D version, it is used for the sprite version, so for rotating character, better use the look at method (the 2.5D tutorials, not the sprite ones). As for the jumping system, raycast actually will be better than using a trigger object as the ground detector, so better only to adapt the jump system using raycast, and leave the other system like described from the tutorial.
-
Watched the 2.5D tutorial up till you went into animation, and while falling is more responsive now on my end, I still have the player sticking on to tagged objects when I hit A or D keys when colliding. And jumping still looks like low gravity. When I use Get Property to increase mass, it's permanent? I want the mass to reset itself.
-
Well you can change its mass when jumping, and upon landing, change the value back to normal, I think that'll do.
-
Well you can change its mass when jumping, and upon landing, change the value back to normal, I think that'll do.
By just setting Get Property, and adding another one at the first state?
-
You can try that, and see if its working or not...
-
How do I set up a boxed trigger to make the player respond back from a previous platform? I'm almost done with stage, but I want to have the player respawn so when they die, they don't have to refresh the web page allover again.
-
Just FYI, this is what I currently have for the project for the raycast kill player issue. No matter what I do for this, I can't seem to get a death and respawn mechanic to work.
https://db.tt/nr0KdLsA
https://db.tt/gIHcYFh8
https://db.tt/3lj0JD8J
https://db.tt/4p88eNLd
https://db.tt/74mXlgrb
https://db.tt/GBgubjos
https://db.tt/PluYBZYQ
-
You can use triggers for this, position each triggers on each of the edge of the platforms, and when it gets triggered by the player, save its position to a vector3 variable, and if the player falls, set the player position back to that saved vector3 variable..
-
You can use triggers for this, position each triggers on each of the edge of the platforms, and when it gets triggered by the player, save its position to a vector3 variable, and if the player falls, set the player position back to that saved vector3 variable..
And if I set up respawn triggers on each platform or on some, would that vector3 variable be local or global? Plus what would that mean for the players death on the bottom dark colored trigger.
This is what I don't get, what actions would be needed like for after the trap destroys the player? Can't it be setting the position even for one single respawn?
-
It would be easier to use global variable for the vector3, though I'd recommend use the local one, and send that variable between object.
Don't destroy the player, just set its position back to the last vector3 stored when the player triggers the last trigger are before he falls.
-
It would be easier to use global variable for the vector3, though I'd recommend use the local one, and send that variable between object.
Don't destroy the player, just set its position back to the last vector3 stored when the player triggers the last trigger are before he falls.
Well destroying the player, that when it's act really weird on my end, like the players main camera is upside down. So even if I use a local vector3 variable, how could the triggers tell where the players position could go, whether it's the first respawn, second, third, and so on?
-
Well that is why the player should not be destroyed, instead reposition it using the vector 3 value, and it is not the trigger who telling the player where it should respawn, but every time the player triggered the trigger object, store that trigger object position, and if the player falls, then reposition the player to that variable. The player will respawn exactly in the trigger position (the last trigger object the player triggered/encountered).
-
And this applies for one whole object that triggers death right?
-
Well this is what I have right now for it.
https://db.tt/B22u2o6m
-
You should create separate trigger object each on the edge of the ground, and give it an action which store its position to a vector3 variable everytime a player trigger enter it. And use that variable to re position the player when it falls..
-
You should create separate trigger object each on the edge of the ground, and give it an action which store its position to a vector3 variable everytime a player trigger enter it. And use that variable to re position the player when it falls..
Therefore by using a vector3 variable it only works if it's a global?
By the way, as in the URL I posted above, do you notice that when the player collides with a wall it sticks instead of slips off of a object or wall?
How can this be fixed?
-
vector3 variable can be global or local, but with local you'll have get or set the variable to transfer its value between FSM, as with global it will be easier, because you can use it right away between FSM, without the need for get or set variable actions.
For stucking issue, just simply create a physics material, and set its friction to 0 (both static and dynamic friction), and apply that material to the player collider component.
-
For sticking issue, just simply create a physics material, and set its friction to 0 (both static and dynamic friction), and apply that material to the player collider component.
How come when I apply the material on the object it doesn't effect the player until I add the same one?
-
Plus, when I set up the death trigger with a local vector3, what would that mean for sending a event to the respawn, since I would have to send a event with a game object specified right?
The issue I have here before setting up the respawn is it will only let me send the player to that spawn trigger if it has a global event. And I don't know if I should make a new FSM for the player since I don't know how that would work with the other scripts, after all the player doesn't have global events on either movement or jumping FSMs.
-
For sticking issue, apply that material to the player, not to the ground or any other object.
And for respawn issue, I'd suggest to watch basic playmaker tutorial, and also tutorial dealing with variable and sending event. Most of the tutorial already covered basic concept for working between object, and it would be easier once you grasp the concept behind playmaker.
-
What kind of basic tutorials are you referring to? Don't recall the basic game design series going into detail when a person applies similar concepts to a spawning system that spawns the player spending where that point or trigger is located, like a check point system or something.
-
the one on hutonggames channel, and also basic logics behind programming, I found most of the unity introduction scripting are quite good. A bit scripting knowledge is useful when using Playmaker.
-
If you were referring to global variables like in the puzzle quest tutorial on hutonggames channel, don't understand how this would apply to using a single instant death object being capable to trigger other objects that respawns the player if each them have different locations.
Just seems to me that it would make more sense if each spawn trigger had a different death collision object representing different positions, given that it wouldn't make sense to add the same value for X,Y,Z on a global variable. So if I used a vector3 with the position value on each axis it would have to be local.
-
I could not get local vector3 variables to work properly, so instead, I made three point points that were globals and 3 separate death triggers.
Then theirs trying to get a handle on or figuring out how to make the player launch off of an object. But this is what I have for the prototype so far.
https://db.tt/6WuMWxGO
Curious about what your feedback is. Appreciate it.
-
Here I've set a quick scene on how I'd do it,
- I'm using separate spawn triggers on each of the edges.
- Set them tags to SpawnPoint, and one big trigger below to detect if the player fall, upon triggering each spawnpoint, the player will store the x position value, under the Trigger Spawn Point FSM.
- and upon falling, when the player trigger the death zone, the next state inside Death/Fall FSM will get the x position value from the Trigger Spawn FSM (I avoid as much as possible using global variable) and then set player position to that X value, with a fixed Y value, in this case 0.7, and 0 on the Z value. All the FSM are only on the player, the spawn point and death trigger does not have any FSM at all.
-
How come it's named unity vs unitypackage?
-
because its a scene, you can put it inside your project folder, and open the scene, I don't use any special assets, just capsule and cubes..
-
when the player trigger the death zone, the next state inside Death/Fall FSM will get the x position value from the Trigger Spawn FSM (I avoid as much as possible using global variable) and then set player position to that X value, with a fixed Y value, in this case 0.7, and 0 on the Z value. All the FSM are only on the player, the spawn point and death trigger does not have any FSM at all.
The problem I am having is that my level isn't intended to be like a flat floor. This doesn't work in this case because the player is dragged below the stage, making it fall continuously.
Is there a way I could add multiple points(empty objects) or add Get Position action with different local variables like a vector3 so my player can spawn at that point?
-
in that case, get X and Y values from the trigger, but when applying the Y axis value to the player, offset it a bit, so the player doesn't stuck on the ground when spawning.
In scripting (or visual scripting in this case) use your imagination where is applicable, be creative when using actions and combining with another action, do this and you will get so far when creating games.
-
in that case, get X and Y values from the trigger, but when applying the Y axis value to the player, offset it a bit, so the player doesn't stuck on the ground when spawning.
So you would say for the players FSM (like your example) that it will work if I add set position more than once on different spawns? That's a problem, because each spawn has a different X and Y value. This is a reason why I went with multiple death triggers in the first place.
-
Yes it would work, but why don't you give it a try before asking here?
-
Adding set position to the death FSM? Or add separate FSMs for each spawn trigger cube?
-
Have you check the sample I've uploaded here? the trigger and the death trigger does not need any FSM at all, all of the FSM are being handled by the character.
-
Spawn for each set position. Therefore, each set position action for each new FSM added to the player including a on trigger event. I am only asking this based on your scene example. So yes, currently the respawn and death trigger do not have FSMs on my end.
-
Posted a new episode of the tutorial series, on how to create weapon system, cheers :)
-
Posted a new episode of the tutorial series, on how to create weapon system, cheers :)
So with that tutorial, you can set up FSMs to collect and switch from weapon to weapon?
-
at this moment no, but you can modify it so it will be able to switch weapon.
-
I guess it's something I will have to do some more research on.
(https://dl.dropboxusercontent.com/u/75323608/reset%20mini%20game%20.png)
I had this issue recently, with trying to have a object set up to create falling prefab objects that made the player respawn without turning the player into a prefab. Can that be done? Because it will only let me use prefabs.
-
I'm sorry, but I didn't quite understand the question, could you explain it a bit more clearer?
-
I'm sorry, but I didn't quite understand the question, could you explain it a bit more clearer?
I have a game manager, it enables another FSM object, that FSM object creates wheels like in the image above. Here's the problem. When I made the wheel a prefab, I made a FSM for it to reset the players position, except I can't do that because it is restricted to only prefab GameObjects. And the player isn't set up to be one. So it's only a gameobject in a scene.
Like when whenever you want to do anything in playmaker, like specifying gameobject, I can only do that to prefabs because the wheel is one. Therefore, no objects in the scene objects window, like when you want to choose whether or not it's scene objects OR prefabs.
So heres my question. Is there a way to make a prefab object respawn/set a non-prefab gameobject's position? Like the player?
Hope that makes more sense to you.
-
well in that case, in the prefab fsm you will need to create a gameObject variable, and then perhaps use "find game object by tag" action to find the game object with player tag in the scene, and then store the result to the variable before, and use that variable to reset its position.
-
well in that case, in the prefab fsm you will need to create a gameObject variable, and then perhaps use "find game object by tag" action to find the game object with player tag in the scene, and then store the result to the variable before, and use that variable to reset its position.
Theirs find Find Game Object. Tried that, and not only it wont collide to the player with a player tag, I get a weird console message about UnityEngine.GUIskin.
-
just uploaded the 8th episode, covering on how to create enemy. Cheers :)
-
New Episodes on the first post for the 2.5D Series, which is part 9 cover Deploying onto Android Device. cheers :)
-
Hi,
just upping this back to 1st page. this is one off the better tutorials for beginners.
-
Hi,
I'm trying to do the 2D Sprite Based Platformer tutorial and everything else is working just fine, but the player has low gravity.
Here's a video to show you what's happening
Thanks
-
@mirautaj: I see on your project, the vector x and y is set to 0, try enabled the equal sign (use parameter option), and make it set to none, see if its working....
-
@mirautaj: I see on your project, the vector x and y is set to 0, try enabled the equal sign (use parameter option), and make it set to none, see if its working....
That worked. thanks!
-
You're welcome. Well basically the vector X and Y set to 0 it interferes with the Y speed, and it tries to set the value to 0 everyframe, that is why it is falling very slowly....