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

#51 2011-12-30 06:19:04

WindowsExplorer
Scratcher
Registered: 2011-02-25
Posts: 1000+

Re: Scratch on Android

ZeroLuck wrote:

WindowsExplorer wrote:

can you release the current version now please?

Sorry, I don't want because:
1. You won't be able to open your own files now.
2. I first want to make rotating and scaling and graphic effects work.
   (Because your projects are using them too!)
3. It has some glitches yet.

Do you understand me?

Yea.  smile


http://i.imgur.com/H6LLdnK.pnghttp://i.imgur.com/VYuD7BY.png

Offline

 

#52 2011-12-31 11:36:31

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

The player supports now nearly all feautures of Scratch.
My big problem is currently: The player is to fast! To fast for things like
Windows Explorer's "LOG" game  sad .
You can see it here.

Here is another test app


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#53 2011-12-31 11:37:50

Dawgles
Scratcher
Registered: 2011-07-29
Posts: 100+

Re: Scratch on Android

Try one of my projects. I don't have an android device so I'm unable to test.

Offline

 

#54 2011-12-31 11:39:31

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

Dawgles wrote:

Try one of my projects. I don't have an android device so I'm unable to test.

Okay.

EDIT

Sorry. I can't test it.
Keyboard control isn't supported in the Android player  sad

Last edited by ZeroLuck (2011-12-31 11:53:35)


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#55 2011-12-31 12:48:55

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

In this Applet you can see how projects are running in the Android player on WINDOWS!...


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#56 2011-12-31 12:54:29

nXIII
Community Moderator
Registered: 2009-04-21
Posts: 1000+

Re: Scratch on Android

ZeroLuck wrote:

The player supports now nearly all feautures of Scratch.
My big problem is currently: The player is to fast! To fast for things like
Windows Explorer's "LOG" game  sad .

I believe the Scratch "normal-speed" stepping rate is around 40-50fps. If your threads yield when Scratch does, just sleep max(0, 1000 / fps - deltaTime) when all threads have yielded or terminated.


nXIII

Offline

 

#57 2011-12-31 12:57:33

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

nXIII wrote:

I believe the Scratch "normal-speed" stepping rate is around 40-50fps. If your threads yield when Scratch does, just sleep max(0, 1000 / fps - deltaTime) when all threads have yielded or terminated.

Thanks!


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#58 2011-12-31 13:40:52

Dawgles
Scratcher
Registered: 2011-07-29
Posts: 100+

Re: Scratch on Android

The rotate block seems to be turning backwards. :S
Is there meant to be a lack of keyboard input? I thought a lot of androids had keyboards.

Normal scratch framerate is 40fps btw

Last edited by Dawgles (2011-12-31 13:47:32)

Offline

 

#59 2011-12-31 14:43:09

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

Dawgles wrote:

The rotate block seems to be turning backwards. :S
Is there meant to be a lack of keyboard input? I thought a lot of androids had keyboards.

Normal scratch framerate is 40fps btw

Do you know how many blocks scratch executes in a second?
That's the thing I want to know because my player has currently
over 1000 blocks in a second  hmm  And I already use a Thread.sleep(1)...

I don't support Keyboard because you can't play a game with the Android keyboard.
That would be fail  big_smile

But you can use the ask block to get user input... (It opens a Dialog in the Android player)


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#60 2011-12-31 14:45:25

Dawgles
Scratcher
Registered: 2011-07-29
Posts: 100+

Re: Scratch on Android

Scratch can execute infinite blocks in a second. Normally, scratch pauses for one frame (at 40fps) every repeat/forever, but when in turbo mode it doesn't do this.

Offline

 

#61 2011-12-31 16:20:17

nXIII
Community Moderator
Registered: 2009-04-21
Posts: 1000+

Re: Scratch on Android

ZeroLuck wrote:

Dawgles wrote:

The rotate block seems to be turning backwards. :S
Is there meant to be a lack of keyboard input? I thought a lot of androids had keyboards.

Normal scratch framerate is 40fps btw

Do you know how many blocks scratch executes in a second?
That's the thing I want to know because my player has currently
over 1000 blocks in a second  hmm  And I already use a Thread.sleep(1)...

I don't support Keyboard because you can't play a game with the Android keyboard.
That would be fail  big_smile

But you can use the ask block to get user input... (It opens a Dialog in the Android player)

After loops & wait blocks (etc.) the thread "yields" until the next frame, when it continues executing where it left off. In turbo mode, the evaluator executes frames continuously until it exceeds a time limit, then repaints once.

In this way, there's no real limit on the number of blocks executed per second or per frame, it's just limited by the length of the stack and where the stack yields.

Last edited by nXIII (2011-12-31 16:21:38)


nXIII

Offline

 

#62 2011-12-31 16:36:05

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

nXIII wrote:

After loops & wait blocks (etc.) the thread "yields" until the next frame, when it continues executing where it left off. In turbo mode, the evaluator executes frames continuously until it exceeds a time limit, then repaints once.

In this way, there's no real limit on the number of blocks executed per second or per frame, it's just limited by the length of the stack and where the stack yields.

This helps me very very much!
I think I will make it like you say in the player.
This should solve the problem.
Thanks!

Last edited by ZeroLuck (2011-12-31 16:36:35)


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#63 2011-12-31 17:43:36

rookwood101
Scratcher
Registered: 2011-07-29
Posts: 500+

Re: Scratch on Android

I quite like the idea of having an insanely fast scratch player; practical  smile


http://i.imgur.com/zeIZW.png

Offline

 

#64 2011-12-31 18:08:49

Boeing747guy
Scratcher
Registered: 2011-01-13
Posts: 17

Re: Scratch on Android

Will this work for older versions like 2.2?


"I'm the man who's gonna burn your house down.. with a lemon!" -Cave Johnson
http://i1188.photobucket.com/albums/z408/Boeing747guy/sigscratch.png

Offline

 

#65 2011-12-31 18:24:14

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

Boeing747guy wrote:

Will this work for older versions like 2.2?

The Android Player?
Why not?


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#66 2011-12-31 18:51:08

rookwood101
Scratcher
Registered: 2011-07-29
Posts: 500+

Re: Scratch on Android

I tried this out on my dad's htc sensation by the way, and it works great!


http://i.imgur.com/zeIZW.png

Offline

 

#67 2011-12-31 18:52:00

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

rookwood101 wrote:

I tried this out on my dad's htc sensation by the way, and it works great!

Which?
The paint.apk?


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#68 2011-12-31 22:12:33

pwiter
Scratcher
Registered: 2010-06-02
Posts: 100+

Re: Scratch on Android

I can help. I know java pretty well and i have a lenovo ideapad k1 with android 3.1. I also have the adb thing for it(delveolped some simple apps)


http://i.imgur.com/YBeXc.png

Offline

 

#69 2011-12-31 22:31:45

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

pwiter wrote:

I can help. I know java pretty well and i have a lenovo ideapad k1 with android 3.1. I also have the adb thing for it(delveolped some simple apps)

Cool!
But there is a problem: The source of the player is very big, more than 4000 lines code  hmm
It'll be hard for you to understand the code...


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#70 2011-12-31 23:13:05

adityasm9
Scratcher
Registered: 2008-03-12
Posts: 100+

Re: Scratch on Android

I can't seem to get to WE's log game..... But paint.apk works well though I'm having trouble bringing the slider back, but maybe that's because I'm trying it out on my small screened phone? I tried this on the applet and it its too fast sometimes and keeps playing the sounds. Also, is there going to be a green flag and the stop button in the player? and finally, are you planning to support variable sliders? Btw seems like you're going full steam ahead! awesome!  big_smile

Offline

 

#71 2012-01-01 05:11:56

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

adityasm9 wrote:

I can't seem to get to WE's log game..... But paint.apk works well though I'm having trouble bringing the slider back, but maybe that's because I'm trying it out on my small screened phone? I tried this on the applet and it its too fast sometimes and keeps playing the sounds. Also, is there going to be a green flag and the stop button in the player? and finally, are you planning to support variable sliders? Btw seems like you're going full steam ahead! awesome!  big_smile

Thanks for the sound bug report!
I will fix that now.
Add a greenflag and a stop button won't be a problem  big_smile
(But I am not sure how It'll look on small devices...)
And I think I will support different Variables types!


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#72 2012-01-01 09:55:55

WindowsExplorer
Scratcher
Registered: 2011-02-25
Posts: 1000+

Re: Scratch on Android

ZeroLuck wrote:

adityasm9 wrote:

I can't seem to get to WE's log game..... But paint.apk works well though I'm having trouble bringing the slider back, but maybe that's because I'm trying it out on my small screened phone? I tried this on the applet and it its too fast sometimes and keeps playing the sounds. Also, is there going to be a green flag and the stop button in the player? and finally, are you planning to support variable sliders? Btw seems like you're going full steam ahead! awesome!  big_smile

Thanks for the sound bug report!
I will fix that now.
Add a greenflag and a stop button won't be a problem  big_smile
(But I am not sure how It'll look on small devices...)
And I think I will support different Variables types!

Why didnt my log game work? Were there errors?


http://i.imgur.com/H6LLdnK.pnghttp://i.imgur.com/VYuD7BY.png

Offline

 

#73 2012-01-01 10:16:37

ZeroLuck
Scratcher
Registered: 2010-02-23
Posts: 500+

Re: Scratch on Android

WindowsExplorer wrote:

ZeroLuck wrote:

adityasm9 wrote:

I can't seem to get to WE's log game..... But paint.apk works well though I'm having trouble bringing the slider back, but maybe that's because I'm trying it out on my small screened phone? I tried this on the applet and it its too fast sometimes and keeps playing the sounds. Also, is there going to be a green flag and the stop button in the player? and finally, are you planning to support variable sliders? Btw seems like you're going full steam ahead! awesome!  big_smile

Thanks for the sound bug report!
I will fix that now.
Add a greenflag and a stop button won't be a problem  big_smile
(But I am not sure how It'll look on small devices...)
And I think I will support different Variables types!

Why didnt my log game work? Were there errors?

The error is in my player...
Your LOG game is getting faster and faster and soon you aren't able to click
the falling blocks  hmm
(It's getting extremly fast, faster than you can see  sad  )

But I search the bug so it will work in some days!!


http://3.bp.blogspot.com/-oL2Atzp0Byw/T465vIQ36dI/AAAAAAAAADo/1vqL4PvhkM0/s1600/scratchdachwiki.png

Offline

 

#74 2012-01-01 10:44:44

MathWizz
Scratcher
Registered: 2009-08-31
Posts: 1000+

Re: Scratch on Android

ZeroLuck wrote:

<crazy sig>

Haha. Nice signature. I didn't happen to have it enabled, but I can see what it'll do.  tongue


http://block.site90.net/scratch.mit/text.php?size=30&amp;text=%20A%20signature!&amp;color=333333

Offline

 

#75 2012-01-01 16:28:11

pwiter
Scratcher
Registered: 2010-06-02
Posts: 100+

Re: Scratch on Android

ZeroLuck wrote:

pwiter wrote:

I can help. I know java pretty well and i have a lenovo ideapad k1 with android 3.1. I also have the adb thing for it(delveolped some simple apps)

Cool!
But there is a problem: The source of the player is very big, more than 4000 lines code  hmm
It'll be hard for you to understand the code...

I'll try my best to make sense of it


http://i.imgur.com/YBeXc.png

Offline

 

Board footer