Discuss Scratch

Tymewalk
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

bjskistad wrote:

Tymewalk wrote:

So Slither development has been dead for a while (partially due to my inactivity on both Scratch and the project).

But! I'm working on fixing that by going through and cleaning out the issues list.

Here's what I'm working on now:
Remove show() and hide()

Here's what needs to be done:
Remove show() and hide() (Working on it now)
Tutorials
Pen (This needs to be discussed at least)
v0.3.0 (As well as this)

Any Slither contributors out there want to get started? Mainly I'm focusing on the discussions, both are cool ideas that should be
Pen would need HTML canvas. Which Python doesn't support as far as I know.
(If you have a GitHub it's best to talk about this there)
I thought you could draw lines with PyGame, no?
bjskistad
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

Tymewalk wrote:

bjskistad wrote:

Tymewalk wrote:

So Slither development has been dead for a while (partially due to my inactivity on both Scratch and the project).

But! I'm working on fixing that by going through and cleaning out the issues list.

Here's what I'm working on now:
Remove show() and hide()

Here's what needs to be done:
Remove show() and hide() (Working on it now)
Tutorials
Pen (This needs to be discussed at least)
v0.3.0 (As well as this)

Any Slither contributors out there want to get started? Mainly I'm focusing on the discussions, both are cool ideas that should be
Pen would need HTML canvas. Which Python doesn't support as far as I know.
(If you have a GitHub it's best to talk about this there)
I thought you could draw lines with PyGame, no?
Lol. I'm not familiar with client side Python. You probably can.
frodewin
Scratcher
500+ posts

Slither - slither from Scratch to Python easily

bjskistad wrote:

Tymewalk wrote:

bjskistad wrote:

Tymewalk wrote:

So Slither development has been dead for a while (partially due to my inactivity on both Scratch and the project).

But! I'm working on fixing that by going through and cleaning out the issues list.

Here's what I'm working on now:
Remove show() and hide()

Here's what needs to be done:
Remove show() and hide() (Working on it now)
Tutorials
Pen (This needs to be discussed at least)
v0.3.0 (As well as this)

Any Slither contributors out there want to get started? Mainly I'm focusing on the discussions, both are cool ideas that should be
Pen would need HTML canvas. Which Python doesn't support as far as I know.
(If you have a GitHub it's best to talk about this there)
I thought you could draw lines with PyGame, no?
Lol. I'm not familiar with client side Python. You probably can.

Python has a turtle graphics package, I'm not sure if it can be used in PyGame projects but otherwise implementation of pen functions should be straightforward.

https://docs.python.org/3/library/turtle.html
Jonathan50
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

bjskistad wrote:

Pen would need HTML canvas. Which Python doesn't support as far as I know.
Um… No.
bjskistad
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

Jonathan50 wrote:

bjskistad wrote:

Pen would need HTML canvas. Which Python doesn't support as far as I know.
Um… No.
Said as far as I know. XD
-Io-
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

bjskistad wrote:

Jonathan50 wrote:

bjskistad wrote:

Pen would need HTML canvas. Which Python doesn't support as far as I know.
Um… No.
Said as far as I know. XD
He meant that you don't need an HTML canvas, not that it supports it
BookOwl
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

Tymewalk wrote:

bjskistad wrote:

Tymewalk wrote:

So Slither development has been dead for a while (partially due to my inactivity on both Scratch and the project).

But! I'm working on fixing that by going through and cleaning out the issues list.

Here's what I'm working on now:
Remove show() and hide()

Here's what needs to be done:
Remove show() and hide() (Working on it now)
Tutorials
Pen (This needs to be discussed at least)
v0.3.0 (As well as this)

Any Slither contributors out there want to get started? Mainly I'm focusing on the discussions, both are cool ideas that should be
Pen would need HTML canvas. Which Python doesn't support as far as I know.
(If you have a GitHub it's best to talk about this there)
I thought you could draw lines with PyGame, no?
You are completely right.
Also, I wont be able to contribute for a while

Last edited by BookOwl (April 27, 2016 20:47:04)

AppLab
Scratcher
100+ posts

Slither - slither from Scratch to Python easily

frodewin wrote:

bjskistad wrote:

Tymewalk wrote:

bjskistad wrote:

Tymewalk wrote:

So Slither development has been dead for a while (partially due to my inactivity on both Scratch and the project).

But! I'm working on fixing that by going through and cleaning out the issues list.

Here's what I'm working on now:
Remove show() and hide()

Here's what needs to be done:
Remove show() and hide() (Working on it now)
Tutorials
Pen (This needs to be discussed at least)
v0.3.0 (As well as this)

Any Slither contributors out there want to get started? Mainly I'm focusing on the discussions, both are cool ideas that should be
Pen would need HTML canvas. Which Python doesn't support as far as I know.
(If you have a GitHub it's best to talk about this there)
I thought you could draw lines with PyGame, no?
Lol. I'm not familiar with client side Python. You probably can.

Python has a turtle graphics package, I'm not sure if it can be used in PyGame projects but otherwise implementation of pen functions should be straightforward.

https://docs.python.org/3/library/turtle.html
http://pygame.org/tags/turtle
There's a turtle for pygame!
Also sound is fixed for slither.
Tymewalk
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

AppLab wrote:

frodewin wrote:

bjskistad wrote:

Tymewalk wrote:

bjskistad wrote:

Tymewalk wrote:

So Slither development has been dead for a while (partially due to my inactivity on both Scratch and the project).

But! I'm working on fixing that by going through and cleaning out the issues list.

Here's what I'm working on now:
Remove show() and hide()

Here's what needs to be done:
Remove show() and hide() (Working on it now)
Tutorials
Pen (This needs to be discussed at least)
v0.3.0 (As well as this)

Any Slither contributors out there want to get started? Mainly I'm focusing on the discussions, both are cool ideas that should be
Pen would need HTML canvas. Which Python doesn't support as far as I know.
(If you have a GitHub it's best to talk about this there)
I thought you could draw lines with PyGame, no?
Lol. I'm not familiar with client side Python. You probably can.

Python has a turtle graphics package, I'm not sure if it can be used in PyGame projects but otherwise implementation of pen functions should be straightforward.

https://docs.python.org/3/library/turtle.html
http://pygame.org/tags/turtle
There's a turtle for pygame!
Also sound is fixed for slither.
Sound fixed? Wonderful!
Also, thanks for those links - I'll be sure to look at them.
Tymewalk
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

The next version is out on PyPi… as 0.2.5.

Yeah. I don't know what went wrong, whenever I try to edit the releases it gives me an error.

Any help would be appreciated, I'd like to fix this.
Tymewalk
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

Tymewalk wrote:

The next version is out on PyPi… as 0.2.5.

Yeah. I don't know what went wrong, whenever I try to edit the releases it gives me an error.

Any help would be appreciated, I'd like to fix this.
Fixed! slither 0.2.2 is now uploaded. Release time!
Tymewalk
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

So I think one of the things we should do is create not just Scratch-like functions, but also Slither-specific convenience functions for PyGame, as well.

A lot of simple tasks like cropping a rect can be tricky, and it would be nice to have a function that can help do that.

What do you guys think?

Last edited by Tymewalk (May 5, 2016 13:31:05)

Tymewalk
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

Tymewalk wrote:

So I think one of the things we should do is create not just Scratch-like functions, but also Slither-specific convenience functions for PyGame, as well.

A lot of simple tasks like cropping a rect can be tricky, and it would be nice to have a function that can help do that.

What do you guys think?
Mega necrobump from the post graveyard

So I'm going to start working on this again. I'll be trying to make some PyGame convenience functions as stated above too, since our audience could be a little wider than just former Scratch users.

Also:

Has someone been mentioning us on StackOverflow?
joefarebrother
Scratcher
500+ posts

Slither - slither from Scratch to Python easily

When it implements all of Scratch's features, would it be possible to write a Scratch -> Python compiler?
Tymewalk
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

joefarebrother wrote:

When it implements all of Scratch's features, would it be possible to write a Scratch -> Python compiler?
Maybe. I'm concerned about variables, I won't be adding things like most operators since they're already built in to pretty much every language. But then there's the question of how to handle them…

I can say for sure the goal is to make it possible to recreate any Scratch project* in Slither, though.

* Except Cloud Projects. You'd need something like PodSixNet for that.
Tymewalk
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

Currently I'd like to work on collisions. They'd be an extremely useful feature to have, and plus once we're done we can make a physics engine with Slither

So Scratch has three types of “touching” blocks:

<touching [ v] ?>
<touching color [#ff0088] ?>
<color [#00ff00] is touching [#0000ff] ?>

Which can be written like this in Slither:
Sprite.touching( OtherSprite ) # Return True or False
Sprite.touchingColor( (255, 0, 0) ) # Accept a color tuple as an argument
Sprite.colorTouchesColor( (255, 0, 0), (0, 255, 0) ) # Accept two color tuples as arguments

The main one I want to work on is the "touching “ block.

Should we start with a simple colliderect test or go straight for the ”pixel perfect" method?
BookOwl
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

@Tymewalk, I would use the colliderect test, it's what scratch uses.
Also, I hope to start working on this some more soon.
Tymewalk
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

BookOwl wrote:

@Tymewalk, I would use the colliderect test, it's what scratch uses.
Also, I hope to start working on this some more soon.
OK! Glad to see you're OK

Here is the pull request with the collision test. Would you mind leaving your thoughts on it there?
BookOwl
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

I got pygame to work on my debian laptop, so I'll start back to work on slither now!
IcyCoder
Scratcher
1000+ posts

Slither - slither from Scratch to Python easily

I think I can help though I have not done Pygame in a while

Powered by DjangoBB