thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
|
| 21 Jul 2013 10:40 AM |
Is this how you build a gun?
1. make your gun 2.Name the handle Handle 3. Insert the gun in "tool" 4. Put this script in the gun '
damage = 50
game:GetService("Debris"):AddItem(script.Parent, 8) function onTouched(hit) if hit.Parent:findFirstChild("Humanoid")~=nil then hit.Parent["Humanoid"]:TakeDamage(damage) end wait() script.Parent:Remove() end script.Parent.Touched:connect(onTouched)
Would those steps work to make a gun? |
|
|
| Report Abuse |
|
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
| |
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
| |
|
|
| 21 Jul 2013 11:10 AM |
Here is an extremely simple way to make a gun.
1.) Build it 2.) Name the handle Handle 3.) Weld parts together (there are many weld scripts on free models) 4.) Anchor = false and CanCollide = false for everything 5.) Put all of the parts in a tool object
6.) Put a script inside Here is an extremely simple example of a script to put inside
script.Parent.Equipped:connect(function(mouse) mouse.Button1Down:connect(function(mouse) local target = mouse.Target if target and target.Parent:findFirstChild("Humaniod") then target.Parent.Humanoid:TakeDamage(15) end end) end) |
|
|
| Report Abuse |
|
|