Posts

How to destroy an object in STYLY through Playmaker

Image
In this tutorial we will learn how we can destroy a 3D model when it collides with other objects in game. For that purpose, we use  is_Trigger in unity 3D and we check the is_Trigger property on that object in which we want to perform some action. In this tutorial, I want to destroy a sphere when a bullet hits it. Make sure you have read previous tutorials on how to access controller and how to fire bullets.    Firstly, create a 3D sphere. That's my target object. 'Now, add a collider and also check the Is Trigger property. Now, the sphere will not block anything. When anything with a collider touches it, the spheres collider will detect that. After that we add a FSM to the sphere. I added action:  Trigger Event in my game as I want to destroy Sphere when a bullet enters in its collider so I added transition of die and lead it to Dying state.            In Dying I added an action of Destroy Self .   I already showed how to c

How to use Virtual reality controllers to create an Amazing bow and arrow Experience in STYLY

Image
Hello Everyone! Today we are going to learn how to use Virtual reality controllers to create an amazing bow and arrow experience. Please make sure you are following the tutorial in a series so you are clear on how to access controllers. Also make sure you have read the STYLY X Playmaker tutorial series here . The basic reason for this tutorial is to guide users on how to infuse kinetics and elasticity into objects. The gist of the tutorial is to multiply a constant with the distance between the 2 hand held controllers for virtual reality. To start off, download free bow and arrow models from 3dwarehouse.sketchup.com. Make sure to turn the models into prefabs and making them a child of an empty object. We will do this as sometimes; models can be tricky to deal with so it is better to envelope them in a game object.                                      Now that we have the prefabs ready, setup the uploadable prefab for STYLY. Follow the setup state in this tutorial. Once one

How to add bullet in controller? STYLY X PlayMaker

Image
How to add bullet in controller? STYLY X PlayMaker In this tutorial we learn about how we add bullet in the controller through playmaker and then upload it into STYLY.   I took a 3D sphere and made it Bullet. Then I apply yellow shade on it, so it’s       looks like Bullet.   After that I added rigid body component on it and also added capsule collider so when it collides to something it will perform specific action. After that I put this bullet into an empty game object named “bullet” and made a prefab of that bullet. After that I selected that bullet and then added an FSM in Playmaker and named that state as Moving forward. I follow this tutorial that already available on STYLY website. I added 2 actions of “add force” and “wait” and set their values that how much force required to a bullet when it move forward and how many second it wait until it destroy. Then I added another state of Dying and set its action as self-destroy. Now we

How to access the controller and change it's default model controller to other model

Image
How to access the controller and change it's default model controller to any other Model: For accessing controller, first we create an empty game object in playmaker hierarchy. The tutorial is already available Here . After that add a state in FSM by selecting  gunController_R.   By following that tutorial I use action find game object and then get position and get rotation of the controller.    After getting position we create variable to store position value of position of controller. Same as above after using action “Get rotation” create variable to store the value of controller. Then, add a 3D model gun “SciFiHand” that will work as shooting gun in this scene. You can add anything. Then add a sphere as child object in front of SciFiHand so it behaves as Spawn point. After that, uncheck its mesh renderer so it’s not visible. We hide it’s mesh because we want its functionality not its mesh. So spawn point is basically the point from

How to create animation in UNITY and then upload it into STYLY

Image
How to create animation in UNITY and then upload it into STYLY First of all, I created a room environment by using 3D plane in UNITY for my Scene. You can select any environment for that purpose. So here I tell you people how to create an animation in unity and then how we upload that in STYLY.   First I created a 3D Sphere which I used as ball. After that I went to window tab in Unity and added animation in it and created the animation for moving a ball. You can add which ever movement you like. In my scene, I added animation of moving right, left, up and down. After adding one ball, I added 3 more balls and added animation on them. After that I uploaded my animation in STYLY. For that purpose, I added all my spheres in one empty game object. I named it “balls” and made a prefab of this. Then I uploaded that prefab into STYLY via the STYLY plugin available. Simply right click the prefab and move your curser to the STYLY option and then select upload