generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: I Need Help With This

Previous Thread :: Next Thread 
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 02:18 PM
If you have ever played BATTLEFIELD by DeadzoneZackZack you know the game is first person... I Have a Script that makes it first person but I can't move the gun up and down... only side to side... I can still look up and down though... Any way to fix this?

The script for first person
script.Parent.Parent.CameraMode = ("LockFirstPerson")
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 02:25 PM
bump
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 02:31 PM
buump
Report Abuse
MHebes is not online. MHebes
Joined: 04 Jan 2013
Total Posts: 2278
09 Jul 2014 02:34 PM
Wow, two of the same concepts right after the other in this subforum.

Here's an explanatory image (Hosted on lmgur) on how to find the angle: /Ffz3NQr.png

Now, just use that to set the C1 of the shoulder(s) on a loop.
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 02:40 PM
Im not going that website
Report Abuse
MHebes is not online. MHebes
Joined: 04 Jan 2013
Total Posts: 2278
09 Jul 2014 02:41 PM
Uh ok I don't want to retype everything I explained in the image... it's just an image hosting website but whatever
Report Abuse
robotmega is not online. robotmega
Joined: 16 May 2009
Total Posts: 14084
09 Jul 2014 02:46 PM
LOLD oders in a nutshell
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 02:57 PM
i know what it is i dont want to create an account
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 02:58 PM
what is the welds Part0 and Part1?
Report Abuse
MHebes is not online. MHebes
Joined: 04 Jan 2013
Total Posts: 2278
09 Jul 2014 03:00 PM
You don't have to create an account but it wouldn't matter because that image just explains the math to you and I can see you don't know how to implement it.
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 03:08 PM
I implemented it and this is the error I got:

16:04:50.350 - Players.Player1.Backpack.Pistol.ShoulderWeld:11: bad argument #3 to 'C1' (CFrame expected, got number)

This is the script:

local plr = Game.Players.LocalPlayer
local head = plr.Character.Head
local mouse = plr:GetMouse()
local angle = math.asin( (mouse.Hit.p - head.Position).unit.Y )
local leftshoulder = Game.Players.LocalPlayer.Character.Torso:WaitForChild("Left Shoulder")
local rightshoulder = Game.Players.LocalPlayer.Character.Torso:WaitForChild("Right Shoulder")

while true do
if leftshoulder and rightshoulder then
leftshoulder.C1 = angle
rightshoulder.C1 = angle
end
end


Any Help.. Please I have been working on this all day and I'm tired of it
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 03:13 PM
bump
Report Abuse
MHebes is not online. MHebes
Joined: 04 Jan 2013
Total Posts: 2278
09 Jul 2014 03:18 PM
'angle' is a number
C1 is a CFrame

You're trying to say

CFrame = number

which makes no sense.

Here's my implementation of it I made a while ago:

http://www.roblox.com/Move-arm-and-neck-item?id=165507770
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 03:36 PM
It doesn't work
Report Abuse
MHebes is not online. MHebes
Joined: 04 Jan 2013
Total Posts: 2278
09 Jul 2014 03:57 PM
Maybe not online but it works for me in studio which means the principles are correct. Read the script, learn how it works, and write your own that does work.
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 04:38 PM
Your script works but since i have one arm welded to another it makes me do the worm
Report Abuse
oscar9999991 is not online. oscar9999991
Joined: 15 Nov 2009
Total Posts: 11373
09 Jul 2014 04:52 PM
bump232322
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image