This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.
  • Index
  •  » Suggestions
  •  » Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

#76 2012-03-17 18:43:56

k9lego
Scratcher
Registered: 2011-09-29
Posts: 59

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

Cloud Saving should have 3 modes:

Load every (number) seconds

Load on enter

Load on command

Last edited by k9lego (2012-03-17 18:45:09)


Hey, I make cool games! WHY NO CLOUD DATA?!?!?!?!!!!!!!! Copy this
Click Here! Stats: http://blocks.scratchr.org/API.php?user=k9lego&action=onlineStatus

Offline

 

#77 2012-03-17 21:56:36

prototype47
Scratcher
Registered: 2010-02-25
Posts: 98

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

k9lego wrote:

Cloud Saving should have 3 modes:

Load every (number) seconds

Load on enter

Load on command

I'm somewhat confused.  What exactly do you mean?


SED is temporarily abandoned while I move onto new areas, such as AI with pathfinding, individual reactions, and group communication.  More complex projects are also brewing.
http://dl.dropbox.com/u/41930734/newsig.png

Offline

 

#78 2012-03-18 06:24:45

scimonster
Community Moderator
Registered: 2010-06-13
Posts: 1000+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

prototype47 wrote:

ImagineIt wrote:

Wait, how would multiplayer games work without a player list? How about "Cloud lists".

I assume that with cloud variables would come cloud lists.

Don't be so sure...

Offline

 

#79 2012-03-19 14:21:05

P110
Scratcher
Registered: 2011-04-12
Posts: 500+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

Hey guys, multiplayer games would work! Like a virtual world (*cough*mine*cough*) you would have slots
e.g.

(player 1 in use)
when gf clicked
if <(player 1 in use) = true>
  broadcast [try player 2 v]
else
  set [player 1 in use] to [true]
  show
  forever
    if <mouse down>
      glide (1) sec to x pos (mouse x) y pos (mouse y)
       set [player 1 x pos v] to (mouse x)
       set [player 1 y pos v] to (mouse y)
    end
  end
end
when gf clicked
if <(player 1 in use) = [true]>
forever
  show
  if <(in(room)) = true>
  glide (1) sec to x pos (player 1 x pos) y pos (player 1 y pos)
  end
end
then this script on stage
when gf clicked
forever
  set [room v] to (background #)
end
Yeah I know it would take a while but hey, as long as it works  smile
also, I would need to think of a way to clear the slots when people leave :s
maybe I would just write a program hosted on my website that clears the slots?

That I would run at night.

Any comments.

Last edited by P110 (2012-03-19 14:35:46)


Me live on 2.0 now  sad

Offline

 

#80 2012-03-20 08:13:45

okofish
New Scratcher
Registered: 2010-09-29
Posts: 24

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

This would be a very nice feature.

Offline

 

#81 2012-03-20 12:05:40

P110
Scratcher
Registered: 2011-04-12
Posts: 500+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

okofish wrote:

This would be a very nice feature.

Hey okofish, welcome to our forum and scratch!


Me live on 2.0 now  sad

Offline

 

#82 2012-03-20 15:25:18

prototype47
Scratcher
Registered: 2010-02-25
Posts: 98

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

P110 wrote:

Hey guys, multiplayer games would work! Like a virtual world (*cough*mine*cough*) you would have slots
e.g.

(player 1 in use)
when gf clicked
if <(player 1 in use) = true>
  broadcast [try player 2 v]
else
  set [player 1 in use] to [true]
  show
  forever
    if <mouse down>
      glide (1) sec to x pos (mouse x) y pos (mouse y)
       set [player 1 x pos v] to (mouse x)
       set [player 1 y pos v] to (mouse y)
    end
  end
end
when gf clicked
if <(player 1 in use) = [true]>
forever
  show
  if <(in(room)) = true>
  glide (1) sec to x pos (player 1 x pos) y pos (player 1 y pos)
  end
end
then this script on stage
when gf clicked
forever
  set [room v] to (background #)
end
Yeah I know it would take a while but hey, as long as it works  smile
also, I would need to think of a way to clear the slots when people leave :s
maybe I would just write a program hosted on my website that clears the slots?

That I would run at night.

Any comments.

Are you saying that

(player 1 in use)
would be a variable managed by Scratch team? Like a variable built into scratch?


SED is temporarily abandoned while I move onto new areas, such as AI with pathfinding, individual reactions, and group communication.  More complex projects are also brewing.
http://dl.dropbox.com/u/41930734/newsig.png

Offline

 

#83 2012-03-20 17:59:45

P110
Scratcher
Registered: 2011-04-12
Posts: 500+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

prototype47 wrote:

P110 wrote:

Hey guys, multiplayer games would work! Like a virtual world (*cough*mine*cough*) you would have slots
e.g.

(player 1 in use)
when gf clicked
if <(player 1 in use) = true>
  broadcast [try player 2 v]
else
  set [player 1 in use] to [true]
  show
  forever
    if <mouse down>
      glide (1) sec to x pos (mouse x) y pos (mouse y)
       set [player 1 x pos v] to (mouse x)
       set [player 1 y pos v] to (mouse y)
    end
  end
end
when gf clicked
if <(player 1 in use) = [true]>
forever
  show
  if <(in(room)) = true>
  glide (1) sec to x pos (player 1 x pos) y pos (player 1 y pos)
  end
end
then this script on stage
when gf clicked
forever
  set [room v] to (background #)
end
Yeah I know it would take a while but hey, as long as it works  smile
also, I would need to think of a way to clear the slots when people leave :s
maybe I would just write a program hosted on my website that clears the slots?

That I would run at night.

Any comments.

Are you saying that

(player 1 in use)
would be a variable managed by Scratch team? Like a variable built into scratch?

No I would add it, also, here is an example http://www.scratch.mit.edu/projects/P110/2411051 press t to change the amount of slots in use as it's not multi-player at the moment.


Me live on 2.0 now  sad

Offline

 

#84 2012-03-21 17:29:40

P110
Scratcher
Registered: 2011-04-12
Posts: 500+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

Hey guys I've revised the script (so it works) LOL! Here it is download to see, I've only fully coded slots: sun: slots 1-4, it explains in description.

http://www.scratch.mit.edu/projects/P110/2411051


Me live on 2.0 now  sad

Offline

 

#85 2012-03-22 15:10:10

k9lego
Scratcher
Registered: 2011-09-29
Posts: 59

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

It should tell you that a list/anything is hooked up to a data base.


Hey, I make cool games! WHY NO CLOUD DATA?!?!?!?!!!!!!!! Copy this
Click Here! Stats: http://blocks.scratchr.org/API.php?user=k9lego&amp;action=onlineStatus

Offline

 

#86 2012-03-24 13:04:58

okofish
New Scratcher
Registered: 2010-09-29
Posts: 24

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

P110 wrote:

okofish wrote:

This would be a very nice feature.

Hey okofish, welcome to our forum and scratch!

Thanks!

Offline

 

#87 2012-03-26 18:06:15

k9lego
Scratcher
Registered: 2011-09-29
Posts: 59

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

Please Make It Scratch Team!!!!


Hey, I make cool games! WHY NO CLOUD DATA?!?!?!?!!!!!!!! Copy this
Click Here! Stats: http://blocks.scratchr.org/API.php?user=k9lego&amp;action=onlineStatus

Offline

 

#88 2012-03-27 09:17:56

k9lego
Scratcher
Registered: 2011-09-29
Posts: 59

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

THEY (scratch) ARE DOING IT!!! YAY!!!


Hey, I make cool games! WHY NO CLOUD DATA?!?!?!?!!!!!!!! Copy this
Click Here! Stats: http://blocks.scratchr.org/API.php?user=k9lego&amp;action=onlineStatus

Offline

 

#89 2012-03-28 15:36:31

P110
Scratcher
Registered: 2011-04-12
Posts: 500+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

k9lego wrote:

THEY (scratch) ARE DOING IT!!! YAY!!!

big_smile


Me live on 2.0 now  sad

Offline

 

#90 2012-05-12 19:17:00

Jonathan50
Scratcher
Registered: 2011-07-06
Posts: 100+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

P110 wrote:

Zeusking19 wrote:

Great idea. Remember this is not only to the ST`s ability, but also what squeak can do.

It will be in flash in 2.0, so it could happen.

Yes but even if they kept it in java due to some un-forseen problem they could program a small python code to manipulate the java applet and connect it up to an sql server.

Thanks for your feedback  smile  O O (meant to be a monkey)
                                            . .
                                            _

please visit my new comment on page 4

It might use flash but for cloud variables and stuff, maybe not because it might just have to change the page itself to change a cloud variable, witch I don't think will be possible in flash or java. I also don't think they'll support characters such as ☁, but in HTML using pre class="scratchblocks" tags you can do any characters. In the forums they change from "scratchblocks" tags in square brackets to pre class="scratchblocks" tags. See;

(☁ Online)
Plus there will not be squeak on it because scratch forgot about software.

Last edited by Jonathan50 (2012-05-12 19:18:32)


Jonathan50
big_smile  http://scratch.mit.edu/img/pages/credits/cat-face-bullet.gif http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=onlineStatus&amp;type=square         http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=projects&amp;type=newest&amp;return=image&amp;num=1

Offline

 

#91 2012-05-12 19:20:44

Jonathan50
Scratcher
Registered: 2011-07-06
Posts: 100+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

add [Cloud Data (☁)] to [☁Online Parties! v ]


Jonathan50
big_smile  http://scratch.mit.edu/img/pages/credits/cat-face-bullet.gif http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=onlineStatus&amp;type=square         http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=projects&amp;type=newest&amp;return=image&amp;num=1

Offline

 

#92 2012-05-12 19:25:09

Jonathan50
Scratcher
Registered: 2011-07-06
Posts: 100+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

The scratch site uses unicode also.


Jonathan50
big_smile  http://scratch.mit.edu/img/pages/credits/cat-face-bullet.gif http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=onlineStatus&amp;type=square         http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=projects&amp;type=newest&amp;return=image&amp;num=1

Offline

 

#93 2012-05-12 19:28:22

Jonathan50
Scratcher
Registered: 2011-07-06
Posts: 100+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

prototype47 wrote:

k9lego wrote:

Cloud Saving should have 3 modes:

Load every (2) seconds

Load on enter

Load on command

I'm somewhat confused.  What exactly do you mean?

I think that.


Jonathan50
big_smile  http://scratch.mit.edu/img/pages/credits/cat-face-bullet.gif http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=onlineStatus&amp;type=square         http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=projects&amp;type=newest&amp;return=image&amp;num=1

Offline

 

#94 2012-05-12 19:30:59

Jonathan50
Scratcher
Registered: 2011-07-06
Posts: 100+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

Code:

(☁ Variable)

Produces...

(☁Variable)
!!!


Jonathan50
big_smile  http://scratch.mit.edu/img/pages/credits/cat-face-bullet.gif http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=onlineStatus&amp;type=square         http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=projects&amp;type=newest&amp;return=image&amp;num=1

Offline

 

#95 2012-05-12 19:37:56

Jonathan50
Scratcher
Registered: 2011-07-06
Posts: 100+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

Using the RecordingControlsMorph (coded "a RecordingControlsMorph()") and cloud variables (☁) you can not only make a text chat room but also talk to each other!!!!!!!!!!!!
To add that morph you must know how to 'Shift-click-R', holding down shift while clicking the R in the scratch logo, witch unfortunetly is only on squeak. Then select 'Turn fill screen off'. Click the white border and select new morph. Browse for the morph.


Jonathan50
big_smile  http://scratch.mit.edu/img/pages/credits/cat-face-bullet.gif http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=onlineStatus&amp;type=square         http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=projects&amp;type=newest&amp;return=image&amp;num=1

Offline

 

#96 2012-05-12 19:46:05

Jonathan50
Scratcher
Registered: 2011-07-06
Posts: 100+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

If in 2.0 you can add morphs to lists and variables like in BYOB, then if you can add table morphs, you could make a cloud database of tables by making a cloud list of tables something like this:

add [a TableMorph(cells:"5" 1296)] to [☁ Events v ]
That would be an events database for a virtual world.
To add pictures to the database you might make a sprite, and run the following:
hide
add [a ScratchSpriteMorph()] to [☁ My idols v ]
If you can't add morphs, then to make tables use vertical bar characters (|), horizontal bar characters (_) and hyper marks. (-) e.g:
add [Hi | Bye] to [☁Hi/Bye v ]
OK, that's just random.

Last edited by Jonathan50 (2012-05-12 20:07:15)


Jonathan50
big_smile  http://scratch.mit.edu/img/pages/credits/cat-face-bullet.gif http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=onlineStatus&amp;type=square         http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=projects&amp;type=newest&amp;return=image&amp;num=1

Offline

 

#97 2012-05-12 20:37:45

Jonathan50
Scratcher
Registered: 2011-07-06
Posts: 100+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

Magnie wrote:

P110 wrote:

prototype47 wrote:

I checked out your website btw. Nice.  Anyway, you could just have the project add their info to one of your cloud lists on the Scratch database.  Wouldn't everything be able to run off of that?  Instead of hosting your own database, just use theirs?

I mean if you really need to use your own database, I'd talk to magnie and look at his (I believe he's a guy) chat.  It's embedded online and can communicate with an online database.
http://zero-bgn.de/scratchgerman/meshjava

Thanks for visiting my website, I'd like to use the integrated scratch version, just to make it a bit easier.

Thanks for the suggestion anyway, because this is what we need! More people interested!

And HI to our new ST friend sdg1

Sadly, at the moment, neither the Java or Flash player support Remote Sensors (which was why ZeroLuck created the Mesh Java Player and on my request  tongue ), but Scratch itself does, which is a great feature! It does, in fact, allow you to connect to Databases if you know how to program in another programming language (Python, PHP, C, etc).

Though one of the problems is that Remote Sensors enables programs to connect to Scratch, but not Scratch to programs. So a way around that is to use a "mirror" which connects to Scratch and to your Server. Then you can have the server parse the messages sent from Scratch and then depending on the message, could change a database of any sort.

I'm very interested in the Cloud Variables idea. Do you know if there will be "open ended" Cloud Variables like this:

ask [What is your name?] and wait
set [name v] to (answer) // Project Variable
set <join (name) [XPos]> to (0) // ☁ Cloud Variable
set <join (name) [YPos]> to (0) // ☁ Cloud Variable

That script would be good for a virtual world, with the new 'clone' block coming out and it's hat, you can copy a 'other players' sprite witch is hidden, and tell it to show up and move to the

(☁whoever xpos)
with the player name, their X position and Y

Last edited by Jonathan50 (2012-05-12 20:53:51)


Jonathan50
big_smile  http://scratch.mit.edu/img/pages/credits/cat-face-bullet.gif http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=onlineStatus&amp;type=square         http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=projects&amp;type=newest&amp;return=image&amp;num=1

Offline

 

#98 2012-05-12 21:10:57

TorbyFork234
Scratcher
Registered: 2012-03-01
Posts: 1000+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

P110 wrote:

Hey guys, multiplayer games would work! Like a virtual world (*cough*mine*cough*) you would have slots
e.g.

(player 1 in use)
when gf clicked
if <(player 1 in use) = true>
  broadcast [try player 2 v]
else
  set [player 1 in use] to [true]
  show
  forever
    if <mouse down>
      glide (1) sec to x pos (mouse x) y pos (mouse y)
       set [player 1 x pos v] to (mouse x)
       set [player 1 y pos v] to (mouse y)
    end
  end
end
when gf clicked
if <(player 1 in use) = [true]>
forever
  show
  if <(in(room)) = true>
  glide (1) sec to x pos (player 1 x pos) y pos (player 1 y pos)
  end
end
then this script on stage
when gf clicked
forever
  set [room v] to (background #)
end
Yeah I know it would take a while but hey, as long as it works  smile
also, I would need to think of a way to clear the slots when people leave :s
maybe I would just write a program hosted on my website that clears the slots?

That I would run at night.

Any comments.

Here is another

when gf clicked
delete (all v) of [☁ everything v]
wait until <<<length of [everything v]>mod [3]>=[0]>
insert <username> at (last v) of [☁ everything v]
insert [0] at (last v) of [☁ everything v] //x position
insert [0] at (last v) of [☁ everything v] //y position
add <username> to [☁ list of people online v]
forever
set [counter v] to [-1]
clear
repeat <<length of [☁ everything v]> * <[2]/[3]>>
change [counter v] by [3]
go to x: <item (counter) of [☁ everything v]> y: <item <(counter)+[1]> of [☁ everything v]>
stamp
end
set [counter v] to [-2]
repeat until <<item (counter) of [☁ everything v]> = <username>>
change [counter v] by [3]
end
if <key [up arrow v] pressed?>
replace item <(counter) + [2]> of [☁ everything v] with <<item <(counter) + [1]> of [☁ everything v]> + [5]>
reset timer
end
if <key [down arrow v] pressed?>
replace item <(counter) + [2]> of [☁ everything v] with <<item <(counter) + [1]> of [☁ everything v]> + [-5]>
reset timer
end
if <key [right arrow v] pressed?>
replace item <(counter) + [1]> of [☁ everything v] with <<item <(counter) + [1]> of [☁ everything v]> + [5]>
reset timer
end
if <key [left arrow v] pressed?>
replace item <(counter) + [1]> of [☁ everything v] with <<item <(counter) + [1]> of [☁ everything v]> + [-5]>
reset timer
end
It would have you be able to move around in a room of scratch cats with other people controlling them. It would only work good if cloud variables are as instantaneous as possible (like the forum posts). also, it wouldn't be able to sense if someone is offline so once your online, you are online forever

Last edited by TorbyFork234 (2012-05-13 01:56:33)

Offline

 

#99 2012-05-12 22:22:14

Jonathan50
Scratcher
Registered: 2011-07-06
Posts: 100+

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

add [a ScratchListMorph(length:'5' 1928)] to [☁Survey Database v ]
you can use lists in other lists (the database) as relationships.


Jonathan50
big_smile  http://scratch.mit.edu/img/pages/credits/cat-face-bullet.gif http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=onlineStatus&amp;type=square         http://blocks.scratchr.org/API.php?user=Jonathan50&amp;action=projects&amp;type=newest&amp;return=image&amp;num=1

Offline

 

#100 2012-05-16 21:33:01

rocketboy100
Scratcher
Registered: 2010-08-19
Posts: 17

Re: Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

How about you could request a SQL database from the scratch team,and you would only be able to add and delete users and see usernames but not the password, email, and any other personal info for multiplayer games. Seems like a better idea than being able to create unlimited troll databases and scams by stealing passwords. Anyone agree?

Offline

 
  • Index
  •  » Suggestions
  •  » Databases (TECH WARNING, COMPLICATED TOPIC) (simple version included)

Board footer