This site requires JavaScript, please enable it in your browser!
Greenfoot back

Comments for Workshop

Return to Workshop

bournebourne

2013/4/30

If you have time, please create a map (can just be a quick one) so I can see how it runs as there are more Users participating. Thanks you
KartoffelbrotKartoffelbrot

2013/4/30

I have made one. Is it anywhere?
bournebourne

2013/4/30

You must "Test" and complete it (reach the Leaf), then hit Confirm to save.
KartoffelbrotKartoffelbrot

2013/4/30

Ok thanks. Have to make it again.
bournebourne

2013/4/30

Sorry it isn't clear that's how to save from the editor interface itself. But it is stated in the help screen.
bournebourne

2013/4/30

Also requiring that you test and complete it just ensures you are not posting an impossible map.
I think it would be more useful for the pressure plate the 'include weight' bit should be 'invert output' instead, that way you can have puzzles where you need to find a weight to open a door. By the way this is awesome and very impressive!
bournebourne

2013/4/30

Does it not cover that? The pressure plate without the setting requires a weight which then can activate a wall/door to appear/disappear. Just accommodated with what is initially placed. And thank you! XD
bournebourne

2013/4/30

Or I mean not initially placed, rather what is currently there at time of activation.
Also it looks like having two portals link to each other causes an error when you try to move things into it :P
bournebourne

2013/4/30

Ha you just divided by zero!
A new version of this scenario was uploaded on Tue Apr 30 22:17:10 UTC 2013 To prevent bad things from happening (bug error), Portals collapse on themselves (acting as solid blocks) should they point to each other.
Also I am a silly and pressure plate inversion is already implemented just not in the way I expected :P
A new version of this scenario was uploaded on Tue Apr 30 23:29:33 UTC 2013 List of Users is now sorted alphabetically. And added Search feature.
A new version of this scenario was uploaded on Tue Apr 30 23:34:43 UTC 2013 List of Users is now sorted alphabetically. And added Search feature. +Correction from last upload
Do you think it would be worth it to compress the 700 or so bits you are using to represent the walls? Also are you currently implementing a version number in one of the available ints so you can change the syntax if you please?
Awesome game, can't wait for more!
JetLennitJetLennit

2013/5/1

Could you do a demo on the search? I have been wanting to do that
Anyone else feel like there should be a discussion on the creations made in this scenario?
JetLennitJetLennit

2013/5/1

http://www.greenfoot.org/topics/3541 Done =)
bournebourne

2013/5/1

Its not exactly just the walls in those 700 some bits. In that it is ordered so that the Game Objects as well can be positioned without storing their positions. Basically reading the map left to right, top to bottom - each cell takes 3 bits automatically. The first 2 bits for whether there are vertical and horizontal walls there (optimized to not include vertical bit for last column, nor horizontal bit for last row). The 3rd bit is whether there is a GameObject there (if so, followed by bits for that). Not sure I know what you mean by compress. Right now I have not touched any of the ints. I have briefly thought of adding a util visible only to me for updating everyone's data for updates, but thought maybe there would be possibility of someone having a copy opened..
Ah that sounds like a good way to do the object positioning. I was envisioning a different scheme, in which some sort of run-length-encoding might have been useful, but your method is a great way to cut memory as well. There might be a way to incorporate some sort of compression to save some space but considering your storage scheme I think it probably would end up not being worth it.
bournebourne

2013/5/1

I did just realize the wall bits don't have to be split up - was just the convenient thing for when writing/reading the Game Objects at the same time.
darkmist255darkmist255

2013/5/1

This is quite interesting! Eager to see the source when it's complete!
bournebourne

2013/5/1

@darkmist255 Thanks! @Builderboy2005 Have you tried putting something together already? There's a couple characters you have to avoid when generating the final Strings to be saved.
What do you mean exactly? I did create a small puzzle map. And yeah I figured that about the strings, probably why you are only able to get 7 bits out of every character yes?
bournebourne

2013/5/1

Yes. Characters 0 - 127 (excluding 13) are persistent through save/load. But you also have to exclude 92 (by itself it seems okay, but fails when followed by anything). So you have to adjust your final string of bits to never include these. Basically I parsed my string of bits and when found a leading 6 bits that could lead to one of the characters, I include these 6 bits plus a bit that makes it not one of these characters, incrementing index only by 6. Then have to accommodate when loading, looking for the leading 6 bits, ignoring the 7th. Doesn't happen too often, but will break your reader / saved data.
bournebourne

2013/5/1

If you haven't already done so, please make a map to share with everyone. Thanks.
bournebourne

2013/5/2

I believe I got a compression working. Gonna test it some more. A blank map cost is at 224.
Oooh very nice. What method did you use to compress the data?
bournebourne

2013/5/2

I rearranged the data so all the horizontal wall bits were together, followed by all the vertical wall bits, followed by the Game Object position place holder bits (that can reference their data which follows at end by ordering). Figure best way to get groups of same bit values together. So it compresses by run-length encoding. Will be using one of the UserInfo's ints to store syntax version.
Sounds pretty awesome! It will be interesting seeing the memory value go up *and* down as you add walls and objects.
bournebourne

2013/5/2

Kinda guessed on a suitable length capacity, and included ability to skip over some bits that don't compress nicely. But of course a chaotic map won't compress well. Made sure that if the compression fails to actually shorten the data, then it isn't applied.
bournebourne

2013/5/2

Some nice submitted maps. Will probably work on pulling data to include in upload next. Got most of it down already. Just need to try to incorporate some sort of management for Users over their maps. (probably will distinguish maps - from individual sets - by name. i.e. Saving of same map name will overwrite). But now I should study for finals...
Game/maniacGame/maniac

2013/5/2

I am logged on but it says please log on
bournebourne

2013/5/2

Did you try again? I had some difficulty with this when I first uploaded this. Try logging out and back in. The only way that happens is if the following returns false: UserInfo.isStorageAvailable()
A new version of this scenario was uploaded on Fri May 03 21:56:22 UTC 2013 1. Uploaded with everyone's maps (those of you that had a map prior to today, you can safely make a 2nd map) Still working on ability to load in editor, maps other than one on server. NOTE: Maps of same name from one on server will be overwritten. 2. Added compression. 3. Included source (Warning: not yet tidy)
bournebourne

2013/5/3

Note: After saving from editor, may need to refresh list of Users
bournebourne

2013/5/3

Also of Note: Loading your previous map then saving - means that you have two versions of it (only one on server is visible - if same map name). And so at this point, to make another map you will be overwriting your changes to your first. Would have to wait until I upload with additional/updated maps again.
A new version of this scenario was uploaded on Sat May 04 01:39:39 UTC 2013
bournebourne

2013/5/4

Well something's not working with UserInfo
A new version of this scenario was uploaded on Sun May 05 04:52:58 UTC 2013
bournebourne

2013/5/6

Storage Server is running again. Thanks to the Greenfoot team. Create a map to share if you haven't already done so (or create a 2nd if you have).
budihckbudihck

2013/8/12

I want to ask, how to put a swing component in Greenfoot area such as buttons, labels, thanks
SPowerSPower

2013/8/12

@budihck Duta has a useful scenario about that: http://www.greenfoot.org/scenarios/5404
budihckbudihck

2013/8/12

@SPower how to declare a new object using a JButton, if the java desktop we only JButton btn = new JButton ("play"); btn.setBounds (50,50,50,50); frame.add (btn); but if in Greenfoot how,,, sorry just learning Greenfoot guidance please
SPowerSPower

2013/8/12

@budihck Please open a new discussion: http://www.greenfoot.org/topics
budihckbudihck

2013/8/12

what if we want to download the project scenarios/5404 for learning materials,,, please help
budihckbudihck

2013/8/12

thanks
A new version of this scenario was uploaded on Mon Nov 18 21:25:04 UTC 2013 Preparation for a project coming soon.