This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2011-08-02 16:11:12

Severus14
Scratcher
Registered: 2011-02-03
Posts: 62

Special Movement Physics Help.

I'm trying to create a SCROLLING game, where the main character is an oval. I want the left and right arrows to turn him, and the up arrow to make the screen go forward (The Scroll X and Scroll Y variables are into play) in the direction that he is pointing in, but I don't know how to make him go in the direction he is pointing in! Please help!

Last edited by Severus14 (2011-08-02 16:11:47)

Offline

 

#2 2011-08-02 17:04:45

Harakou
Community Moderator
Registered: 2009-10-11
Posts: 1000+

Re: Special Movement Physics Help.

Hm... I think that might require some trig... Give me some time and I may be able to come up with a solution.


http://www.blocks.scratchr.org/API.php?action=random&return=image&link1=http://i.imgur.com/OZn2RD3.png&link2=http://i.imgur.com/duzaGTB.png&link3=http://i.imgur.com/CrDGvvZ.png&link4=http://i.imgur.com/POEpQyZ.png&link5=http://i.imgur.com/ZKJF8ac.png

Offline

 

#3 2011-08-02 17:10:56

Death_Wish
Scratcher
Registered: 2011-07-26
Posts: 1000+

Re: Special Movement Physics Help.

Doesn't this belong in Advanced Topics?
And congratulations on being a moderator Harakou, you totally deserve it  big_smile
But I'd recommend getting a signature  tongue


With a straight flush.
http://4.bp.blogspot.com/-FlUhnzmIROE/TgtpjdJl4tI/AAAAAAAABCM/W19pvFTZFaU/s1600/save_the_world.png http://blocsonic.com/images/special/rip-stevejobs.jpg

Offline

 

#4 2011-08-02 17:16:11

Harakou
Community Moderator
Registered: 2009-10-11
Posts: 1000+

Re: Special Movement Physics Help.

Death_Wish wrote:

Doesn't this belong in Advanced Topics?
And congratulations on being a moderator Harakou, you totally deserve it  big_smile
But I'd recommend getting a signature  tongue

Nope. It's a common misconception that topics about more advanced scripting like trig go in the Advanced Topics forum, but it's actually only intended for threads about working with the source code and stuff like that.

And thank you.  smile


http://www.blocks.scratchr.org/API.php?action=random&return=image&link1=http://i.imgur.com/OZn2RD3.png&link2=http://i.imgur.com/duzaGTB.png&link3=http://i.imgur.com/CrDGvvZ.png&link4=http://i.imgur.com/POEpQyZ.png&link5=http://i.imgur.com/ZKJF8ac.png

Offline

 

#5 2011-08-02 17:17:56

henley
Scratcher
Registered: 2008-06-21
Posts: 1000+

Re: Special Movement Physics Help.

Death_Wish wrote:

Doesn't this belong in Advanced Topics?
And congratulations on being a moderator Harakou, you totally deserve it  big_smile
But I'd recommend getting a signature  tongue

I can understand you thinking it might belong in Advanced Topics, but this is not an Advanced Topic. It is about Scratch. Therefore goes into the AAS Forum. Advanced Topics usually have to do with Scratch as a programming language. (i.e. Mods, source code, Squeak, etc)

And I agree that Harakou should get a sig, but nothing to unprofessional. I see you in my mind as a business (wo)man.


"I've worked so hard for you and you give me nothing in return. Do you need help... Or do I?"

Offline

 

#6 2011-08-02 17:18:04

Death_Wish
Scratcher
Registered: 2011-07-26
Posts: 1000+

Re: Special Movement Physics Help.

Harakou wrote:

Death_Wish wrote:

Doesn't this belong in Advanced Topics?
And congratulations on being a moderator Harakou, you totally deserve it  big_smile
But I'd recommend getting a signature  tongue

Nope. It's a common misconception that topics about more advanced scripting like trig go in the Advanced Topics forum, but it's actually only intended for threads about working with the source code and stuff like that.

And thank you.  smile

I see. So if I have a question about programming on Scratch because I can't figure out something I should post it on here? I didn't know that  big_smile  I'll do that from now on, then.


With a straight flush.
http://4.bp.blogspot.com/-FlUhnzmIROE/TgtpjdJl4tI/AAAAAAAABCM/W19pvFTZFaU/s1600/save_the_world.png http://blocsonic.com/images/special/rip-stevejobs.jpg

Offline

 

#7 2011-08-02 20:30:47

Severus14
Scratcher
Registered: 2011-02-03
Posts: 62

Re: Special Movement Physics Help.

Harakou wrote:

Hm... I think that might require some trig... Give me some time and I may be able to come up with a solution.

Thanks. And congrats about becoming a Moderator!

Offline

 

#8 2011-08-02 23:06:28

Harakou
Community Moderator
Registered: 2009-10-11
Posts: 1000+

Re: Special Movement Physics Help.

Aha! I got it. Sorry for taking a while; Scratch's direction system always gives me a hard time. I've posted a project demonstrating the concept here, which I hope helps you out. I also included some more information in comments attached to the scripts. If you need any help adapting it to your project, feel free to ask.  smile

And thank you!  big_smile


http://www.blocks.scratchr.org/API.php?action=random&return=image&link1=http://i.imgur.com/OZn2RD3.png&link2=http://i.imgur.com/duzaGTB.png&link3=http://i.imgur.com/CrDGvvZ.png&link4=http://i.imgur.com/POEpQyZ.png&link5=http://i.imgur.com/ZKJF8ac.png

Offline

 

Board footer