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

#76 2012-10-12 05:15:58

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: M30W New Official Topic

k, commited, make sure to upgrade to r52! (you can now save/load to/from .m30w files) and test it xD

Offline

 

#77 2012-10-12 05:55:46

blob8108
Scratcher
Registered: 2007-06-25
Posts: 1000+

Re: M30W New Official Topic

roijac wrote:

k, commited, make sure to upgrade to r52! (you can now save/load to/from .m30w files) and test it xD

Cool!  smile  But why aren't you just saving using Kurt?  tongue


Things I've made: kurt | scratchblocks2 | this cake

Offline

 

#78 2012-10-12 06:52:28

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: M30W New Official Topic

blob8108 wrote:

roijac wrote:

k, commited, make sure to upgrade to r52! (you can now save/load to/from .m30w files) and test it xD

Cool!  smile  But why aren't you just saving using Kurt?  tongue

1. it's pretty slow, so it disturbs the work flow when saving every few minutes
2. slinger hasn't yet implemented it  big_smile

did you ever think of using cython to make kurt faster?

Offline

 

#79 2012-10-12 07:05:56

slinger
Scratcher
Registered: 2011-06-21
Posts: 1000+

Re: M30W New Official Topic

Yeah, sorry about that  tongue
I'm really busy right now but once the constant flow of school work dies down expect something from me :p


http://s0.bcbits.com/img/buttons/bandcamp_130x27_blue.png

Offline

 

#80 2012-10-12 07:22:26

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: M30W New Official Topic

slinger wrote:

Yeah, sorry about that  tongue
I'm really busy right now but once the constant flow of school work dies down expect something from me :p

np  smile
do you want me to take the saving? once we have that we can release an official alpha or something

Offline

 

#81 2012-10-12 11:16:27

Magnie
Scratcher
Registered: 2007-12-12
Posts: 1000+

Re: M30W New Official Topic

blob8108 wrote:

Magnie wrote:

blob8108 wrote:


Ah. You need to at least run setup.py  tongue

Oh well.  tongue

Fine, then. At least install all the dependencies!

I installed PLY like I was supposed to.

Offline

 

#82 2012-10-12 11:59:58

LiquidMetal
Scratcher
Registered: 2011-06-15
Posts: 500+

Re: M30W New Official Topic

roijac wrote:

well, i'd love too, but that involves deb packaging M30W, which isn't THAT easy.
maybe you could make the scripts?

some links:
http://stackoverflow.com/questions/1382569/how-do-i-do-debian-packaging-of-a-python-package
http://wiki.debian.org/Python/Packaging
http://savetheions.com/2010/01/20/packaging-python-applicationsmodules-for-debian/

Sounds like fun...  But I don't have time to try this right now.  Maybe I'll try to do it at some point in the future, but I'm going back to school (no internet) in two days  sad . I'll put a text file with relevant information on my USB so I'll remember to try when I have a chance (likely not for a while)  tongue .

Offline

 

#83 2012-10-12 13:21:58

blob8108
Scratcher
Registered: 2007-06-25
Posts: 1000+

Re: M30W New Official Topic

roijac wrote:

blob8108 wrote:

roijac wrote:

k, commited, make sure to upgrade to r52! (you can now save/load to/from .m30w files) and test it xD

Cool!  smile  But why aren't you just saving using Kurt?  tongue

1. it's pretty slow, so it disturbs the work flow when saving every few minutes

I get <10 seconds on my roads thing  tongue  Is that still too long? Or do you just have lots of images?

And this is after I made saving 150x faster...  tongue  (The comparison isn't quite fair, because the algorithm I replaced was in exponential time, I think. But you get the idea...)

2. slinger hasn't yet implemented it  big_smile

Fair enough  tongue  By the way, why don't you use Kurt objects directly, rather than converting to/from? I was thinking you'd have a kind of Model-View thing, where you'd have Kurt classes as your model; and SpriteView, StageView, etc classes that would each bind to a model object and would manipulate it.

did you ever think of using cython to make kurt faster?

Oh no, not another dependency...  tongue

I suppose I could add optional psyco support. But it never really seemed to make things that much faster for me...


Things I've made: kurt | scratchblocks2 | this cake

Offline

 

#84 2012-10-12 14:04:26

slinger
Scratcher
Registered: 2011-06-21
Posts: 1000+

Re: M30W New Official Topic

roijac wrote:

slinger wrote:

Yeah, sorry about that  tongue
I'm really busy right now but once the constant flow of school work dies down expect something from me :p

np  smile
do you want me to take the saving? once we have that we can release an official alpha or something

Sure, I will try to get active again but I'm having trouble doing many things that I would like to do :C


http://s0.bcbits.com/img/buttons/bandcamp_130x27_blue.png

Offline

 

#85 2012-10-12 14:08:35

blob8108
Scratcher
Registered: 2007-06-25
Posts: 1000+

Re: M30W New Official Topic

Magnie wrote:

blob8108 wrote:

Magnie wrote:


Oh well.  tongue

Fine, then. At least install all the dependencies!

I installed PLY like I was supposed to.

Are you still seeing "WARNING: parser not available, requires PLY" messages when you import kurt?


Things I've made: kurt | scratchblocks2 | this cake

Offline

 

#86 2012-10-12 17:18:04

Magnie
Scratcher
Registered: 2007-12-12
Posts: 1000+

Re: M30W New Official Topic

blob8108 wrote:

Magnie wrote:

blob8108 wrote:


Fine, then. At least install all the dependencies!

I installed PLY like I was supposed to.

Are you still seeing "WARNING: parser not available, requires PLY" messages when you import kurt?

Yeah. The htmlcolor is the one causing the error (I added a print Exception  tongue ).

Offline

 

#87 2012-10-13 02:42:16

blob8108
Scratcher
Registered: 2007-06-25
Posts: 1000+

Re: M30W New Official Topic

Magnie wrote:

blob8108 wrote:

Magnie wrote:


I installed PLY like I was supposed to.

Are you still seeing "WARNING: parser not available, requires PLY" messages when you import kurt?

Yeah. The htmlcolor is the one causing the error (I added a print Exception  tongue ).

Ah, I think that makes sense. Have you tried copying the htmlcolor folder to the directory containing "M30W.py"?


Things I've made: kurt | scratchblocks2 | this cake

Offline

 

#88 2012-10-13 11:37:04

Magnie
Scratcher
Registered: 2007-12-12
Posts: 1000+

Re: M30W New Official Topic

blob8108 wrote:

Magnie wrote:

blob8108 wrote:


Are you still seeing "WARNING: parser not available, requires PLY" messages when you import kurt?

Yeah. The htmlcolor is the one causing the error (I added a print Exception  tongue ).

Ah, I think that makes sense. Have you tried copying the htmlcolor folder to the directory containing "M30W.py"?

Ah.. That would make sense. Didn't know there was one.  tongue

Offline

 

#89 2012-10-13 13:51:58

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: M30W New Official Topic

blob8108 wrote:

2. slinger hasn't yet implemented it  big_smile

Fair enough  tongue  By the way, why don't you use Kurt objects directly, rather than converting to/from? I was thinking you'd have a kind of Model-View thing, where you'd have Kurt classes as your model; and SpriteView, StageView, etc classes that would each bind to a model object and would manipulate it.

because I want the kurt & construct dependency optional for 1.4 files manipulation
don't take it personally  tongue

Offline

 

#90 2012-10-15 14:13:21

blob8108
Scratcher
Registered: 2007-06-25
Posts: 1000+

Re: M30W New Official Topic

roijac wrote:

blob8108 wrote:

2. slinger hasn't yet implemented it  big_smile

Fair enough  tongue  By the way, why don't you use Kurt objects directly, rather than converting to/from? I was thinking you'd have a kind of Model-View thing, where you'd have Kurt classes as your model; and SpriteView, StageView, etc classes that would each bind to a model object and would manipulate it.

because I want the kurt & construct dependency optional for 1.4 files manipulation
don't take it personally  tongue

Hmm, fair enough, I guess. You could always package kurt with M30W, and only use the Construct-y parts when you need to, or something...


Things I've made: kurt | scratchblocks2 | this cake

Offline

 

#91 2012-10-19 12:03:29

blob8108
Scratcher
Registered: 2007-06-25
Posts: 1000+

Re: M30W New Official Topic

wx/M30W detest running on OS X.  tongue


Things I've made: kurt | scratchblocks2 | this cake

Offline

 

#92 2012-10-19 12:16:15

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: M30W New Official Topic

blob8108 wrote:

wx/M30W detest running on OS X.  tongue

everybody does

jk, what are the problems?

Offline

 

#93 2012-10-19 12:23:41

blob8108
Scratcher
Registered: 2007-06-25
Posts: 1000+

Re: M30W New Official Topic

I'm afraid I can't give any useful error reports. Everything just seems... crashy.  tongue

I might try it another time, and give you more useful feedback  smile


Things I've made: kurt | scratchblocks2 | this cake

Offline

 

#94 2012-10-22 16:40:06

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: M30W New Official Topic

so, i finished anything about saving except for parsing and saving code, which is obviously the hardest one
@blob, in the kurt manual you say sprite attributes aren't saved, maybe you should add x&y attrs to the kurt.Sprite object and redefine bounds on save, because this method worked for me  smile

Offline

 

#95 2012-10-23 03:40:40

blob8108
Scratcher
Registered: 2007-06-25
Posts: 1000+

Re: M30W New Official Topic

roijac wrote:

so, i finished anything about saving except for parsing and saving code, which is obviously the hardest one

It's not so bad! You can just use the function from Kurt, can't you?  smile

@blob, in the kurt manual you say sprite attributes aren't saved, maybe you should add x&y attrs to the kurt.Sprite object and redefine bounds on save, because this method worked for me  smile

Perhaps — then I'd probably have to store width and height as well, though...

"Kurt manual"? Where do I say that?!  tongue


Things I've made: kurt | scratchblocks2 | this cake

Offline

 

#96 2012-10-23 09:42:31

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: M30W New Official Topic

blob8108 wrote:

Perhaps — then I'd probably have to store width and height as well, though...

I'm using this code to generate bounds:

Code:

rx, ry = self.costume.rotationCenter
x1, y1 = self.x, self.y
x1 -= rx - 240
y1 += ry - 180
y1 *= -1
w, h = self.costume.width, self.costume.height
x2, y2 = x1 + w, y1 + h
self.bounds = Rectangle([x1, y1, x2, y2])

blob8108 wrote:

"Kurt manual"? Where do I say that?!  tongue

https://github.com/blob8108/kurt#notes--restrictions

Last edited by roijac (2012-10-23 09:47:22)

Offline

 

#97 2012-10-23 09:47:08

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

Re: M30W New Official Topic

code wrote:

Code:

x1 -= rx - 240
y1 += ry - 180

WHAT? ARE THOSE KONSTANST? :OOOO

I believe that the x and y position comes from the origin of the rectangle plus the rotation center of the costume.


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

Offline

 

#98 2012-10-23 09:52:10

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: M30W New Official Topic

MathWizz wrote:

code wrote:

Code:

x1 -= rx - 240
y1 += ry - 180

WHAT? ARE THOSE KONSTANST? :OOOO

I believe that the x and y position comes from the origin of the rectangle plus the rotation center of the costume.

exactly
only that with the saving, scratch turns the y axis upside down and starts counting from top left stage corner  wink

Offline

 

#99 2012-10-23 09:56:25

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

Re: M30W New Official Topic

roijac wrote:

only that with the saving, scratch turns the y axis upside down and starts counting from top left stage corner  wink

Also, the x position and y position of a sprite are at the center of its "bounds" rectangle.


nXIII

Offline

 

#100 2012-10-23 09:57:23

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

Re: M30W New Official Topic

I spent three days trying to figure that out.

...the amount I trig I couldn't get to work...

*sigh*


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

Offline

 

Board footer