|
| 20 Dec 2013 01:23 PM |
Hello. I want to make sci-fi fighters for a group of mine and can make the shell of the plane fine. I have begun to learn how to script and can do basic things like making doors with buttons, text box etc. However I am having trouble scripting plane seats that contain weapons. I can't find a guide to help me so if someone can refer me to a wiki guide on it (have looked on official roblox wiki)that would be helpful or if someone can give me some help here, that would also be very much appreciated. :) |
|
|
| Report Abuse |
|
|
|
| 20 Dec 2013 01:29 PM |
| VehicleSeats are not a wise way of storing Tools because the VehicleSeat is a physical object, as are the Tools. Parenting the Tools to the VehicleSeat will result in nothing more than the Tool staying where it is. It's better to place them in Lighting or Serverstorage. Do not use ReplicatedStorage for anything, ever. The reason being that ReplicatedStorage doesn't always replciate it's contents to your players, causing various bugs to occur. It's better to store them elsewhere and just clone them through a script. |
|
|
| Report Abuse |
|
|
|
| 21 Dec 2013 02:05 AM |
| so how would I script it in order for it to give the aircraft tool to players when they sit on the seat? |
|
|
| Report Abuse |
|
|
|
| 21 Dec 2013 10:27 AM |
| use the childadded method on the vehicle seat and find the weld that appears. find the character through part1 in the weld and then use the getplayerfromcharacter method to find the player. then clone the tools to the player's backpack. same way when they jump off the vehicleseat. you can use the childremoving method and repeat steps 2 and 3. |
|
|
| Report Abuse |
|
|
|
| 22 Dec 2013 06:07 AM |
| Ah ok, thanks for the help. |
|
|
| Report Abuse |
|
|