[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[kidsgames] Re: Kids Game Builder version 0.0.1



Hello Chris,

On Mon, 27 Sep 1999, Chris Ellec wrote:

> >
> > Boy have we got an adventure in front of us ;)
> >
> 
> this lists seems off to a great start ... cool !
> 

Just hope I can keep up.

> >
> > I'm thinking that we want a simple database backend, perhaps mysql the gpl
> > version.  Then that means we need to define the schema for the database.
> > I think we will need a minimum of the following:
> >
> >
> 
> I guess you could put everything in one database, as long as you can use the
> right tools and queries to get the data in and out of it.
> OTOH maybe one database for math games, one for foreign languages, one for
> arts, etc. might be easier to administer.
> 

It seems we need to have the potential to have one big database, made up
of MANY smaller databases so we CAN glob it all together, but also take
just what we need when we need it.  Hmmmmm.

> >
> >  2) A storyline.  So we need a way to customize the Game to create
> > story lines and allow for rewards when problems are well answered.
> 
> Tux goes to the market. He buys 2 fishes at $2 and 3 fishes at $4. (Insert
> local currency). How much did he spend ?
> 
> When Tux gets home,  he eats 1/3 of the first fish. How much of that fish is
> left ?
> If Tux cuts a fish in 6 and eat 2 pieces for each meal, how many meals can he
> have ?
> 

Nice ... Let's see.  quick perl script to automate this might look
something like....


----
#/usr/bin/perl
#these need to be randomized.
#probably fixed to a particular range for particular skillsets
$number_of_first_fish=2;
$number_of_second_fish=3;
$price_of_second_fish=2;
$price_of_first_fish=4;

$numberoftries = 0;

print "Tux goes to the market.  He buys $number_of_first_fish fish at
        $price_of_first_fish dollars and $number_of_second_fish fish
at
        $price_of_second_fish dollars.
        \nHow much did he spend?";


while (<>)
{
        if (($numberoftries) > 10)
        {
                print "You have been incorrect $numberoftries times.
Do you want
to know the answer?";
                $answer = <>;
                if ($answer =~ "yes")
                {
                        print "\nTux spent" + (($number_of_second_fish 
*
$price_of_second_fish) + ($number_of_first_fish *
$price_of_first_fish)) +
"dollars.\n";
                        exit;
                }
        }
        if ($_ != ($number_of_second_fish * $price_of_second_fish) +
                ($number_of_first_fish * $price_of_first_fish))
        {
                print "I\'m sorry that is incorrect.  Please try
again!\n";
                $numberoftries++;
        }
        else
        {
                print "You are correct.  Great JOB!!!\n";
                exit;
        }
        print "Tux goes to the market.  He buys $number_of_first_fish
fish at
                $price_of_first_fish dollars and
$number_of_second_fish fish at
                $price_of_second_fish dollars.
                \nHow much did he spend?\n";
}
----

Enough silly perl scripting ;)

This is very rudimentary and would require a GREAT deal of work to get 
to be useful in the general sense, but this can fairly easily be expanded
and made much more flexible....

Sincerely

Jeff Waddell
jeff@smluc.org

-
kidgames@smluc.org  -- To get off this list send "unsubscribe" in the
body of a message to majordomo@smluc.org