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 » Scripters
Home Search
 

Re: Fail attempt with arm animations

Previous Thread :: Next Thread 
PersistentData is not online. PersistentData
Joined: 04 Apr 2011
Total Posts: 6224
07 Aug 2011 05:00 PM
it supposed to move the arm pointing at the mouse's position. so when you zoom in, it should keep in place on one area.

    coroutine.wrap(function()
        while wait() do
            local x, y, z = mouse.Hit:toEulerAnglesXYZ()
            char.Torso["Right Shoulder"].CurrentAngle = y
        end
    end)()

...HELP
Report Abuse
Sorcus is not online. Sorcus
Forum Moderator
Joined: 29 Nov 2010
Total Posts: 3775
07 Aug 2011 05:00 PM
See the Dracovin's wand :)

~Sorcus
Report Abuse
sckum555 is not online. sckum555
Joined: 20 Aug 2008
Total Posts: 6576
07 Aug 2011 05:01 PM
"...HELP "

scripter ...HELPers
Report Abuse
sncplay42 is not online. sncplay42
Joined: 27 Nov 2008
Total Posts: 11891
07 Aug 2011 05:02 PM
coroutine.wrap(function()
while wait() do
local x, y, z = (mouse.Hit - char.Torso["Right Shoulder"].Position):toEulerAnglesXYZ()
char.Torso["Right Shoulder"].CurrentAngle = y
end
end)()

No idea if that works.

Also y u no just use Spawn()
Report Abuse
Oysi is not online. Oysi
Joined: 06 Jul 2009
Total Posts: 9058
07 Aug 2011 05:04 PM
[ Content Deleted ]
Report Abuse
PersistentData is not online. PersistentData
Joined: 04 Apr 2011
Total Posts: 6224
07 Aug 2011 05:06 PM
["Right Shoulder"].Position? o_O
Also, is spawn() more efficient or something? I use coroutines just because I think that it is more powerful.
Report Abuse
Oysi is not online. Oysi
Joined: 06 Jul 2009
Total Posts: 9058
07 Aug 2011 05:06 PM
[ Content Deleted ]
Report Abuse
sncplay42 is not online. sncplay42
Joined: 27 Nov 2008
Total Posts: 11891
07 Aug 2011 05:07 PM
Spawn()'s just more concise

Powerfulness means little when you're just going to do what the concise thing does
Report Abuse
Oysi is not online. Oysi
Joined: 06 Jul 2009
Total Posts: 9058
07 Aug 2011 05:09 PM
[ Content Deleted ]
Report Abuse
sncplay42 is not online. sncplay42
Joined: 27 Nov 2008
Total Posts: 11891
07 Aug 2011 05:10 PM
CurrentAngle = math.pi / 2 + Mouse.Hit.lookVector.y

Pretty sure there's some trig functions missing there
Report Abuse
sncplay42 is not online. sncplay42
Joined: 27 Nov 2008
Total Posts: 11891
07 Aug 2011 05:11 PM
>.lookVector

Never mind.
Report Abuse
Razer100 is not online. Razer100
Joined: 28 Aug 2009
Total Posts: 8066
07 Aug 2011 05:12 PM
Vectors, look, .


think

-R- ~!SS!~ ~ రేజర్ ~
Report Abuse
Oysi is not online. Oysi
Joined: 06 Jul 2009
Total Posts: 9058
07 Aug 2011 05:13 PM
[ Content Deleted ]
Report Abuse
sncplay42 is not online. sncplay42
Joined: 27 Nov 2008
Total Posts: 11891
07 Aug 2011 05:13 PM
^I'm not sure what you're trying to say
Report Abuse
sncplay42 is not online. sncplay42
Joined: 27 Nov 2008
Total Posts: 11891
07 Aug 2011 05:14 PM
>_< oysi

>_< floodcheck
Report Abuse
Oysi is not online. Oysi
Joined: 06 Jul 2009
Total Posts: 9058
07 Aug 2011 05:14 PM
[ Content Deleted ]
Report Abuse
NXTBoy is not online. NXTBoy
Joined: 25 Aug 2008
Total Posts: 4533
07 Aug 2011 05:14 PM
"local x, y, z = cframe:toEulerAnglesXYZ()"

Never do this.

NEVER EVER EVER DO THIS

It is never what you actually want. Let me reiterate: it is not what you want.
Report Abuse
sncplay42 is not online. sncplay42
Joined: 27 Nov 2008
Total Posts: 11891
07 Aug 2011 05:15 PM
THAT wasn't. :P
Report Abuse
Oysi is not online. Oysi
Joined: 06 Jul 2009
Total Posts: 9058
07 Aug 2011 05:15 PM
[ Content Deleted ]
Report Abuse
sncplay42 is not online. sncplay42
Joined: 27 Nov 2008
Total Posts: 11891
07 Aug 2011 05:15 PM
My last post was, though.

Third time this thread D:
Report Abuse
NXTBoy is not online. NXTBoy
Joined: 25 Aug 2008
Total Posts: 4533
07 Aug 2011 05:19 PM
@Oysi: I'm still gonna go with no. What you should be using is:

var yAngle = math.atan2(lookVector.x, lookVector.y)

I'll modify my statement: :toEulerAngles() only does what you want if you're looking for the Y rotation. Normally.
Report Abuse
NXTBoy is not online. NXTBoy
Joined: 25 Aug 2008
Total Posts: 4533
07 Aug 2011 05:20 PM
Oops:

var yAngle = math.atan2(lookVector.x, lookVector.z)
Report Abuse
thegenius is not online. thegenius
Joined: 03 Oct 2008
Total Posts: 3838
07 Aug 2011 05:23 PM
Never knew what coroutine.wrap() was. Now, it's awesome.

coroutine.wrap(function() while wait() do print("OLOL") end end)

(Note: Math FTW)
Report Abuse
Oysi is not online. Oysi
Joined: 06 Jul 2009
Total Posts: 9058
07 Aug 2011 05:23 PM
[ Content Deleted ]
Report Abuse
NXTBoy is not online. NXTBoy
Joined: 25 Aug 2008
Total Posts: 4533
07 Aug 2011 05:25 PM
Can't tell if genuine, sarcastic, or not aimed at me.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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