I think this project has gone beyond the scope of my knowledge. I will be watching though.
WHOAAAAAAAAAAAA THERE, WAIT A MINUTE. SeiferTim, that icon of yours… however are those little dudes made? I mean… if pixel by pixel… how the color blending and such?
I’ve always wondered how those were made, I’ve tried going in paint, zoom in reeeeeeeaaaaaally close, then set Black on left mouse button and White on right mouse button… twas forever taking.
Sorry, all this just kinda hit me after the gigantic headache.
Anyway, I’m currently learning how to use Freehand 10… I’ve been avoiding it because the first few times I’ve tried to use it I was entirely confused. That drawing I did a few posts ago was all in Flash… no wonder it was so hard.
Sigh, the library lady is getting mad at me because I’m not suppose to be on the computers (There’s at least 30 of them for crying out loud) if I’m not doing a school related project. So ----------------------- buh-bye
I think the one I have right now was made a few years (yes, I’ve been using it for years) ago in Paint Shop Pro. You can use just about anything you want, I can do some in Photoshop, and yes, they do take a long time to make. However, if we have someone who is good at pixel art, I think it would be the best way to create the style of the program.
Hi seifer
*Originally posted by Lady Miaka *
**Hi seifer **
Hello, Miaka. How are you? :beam:
Ive been reading through this, and I have a few theoretical ideas:
To have full AI, one must program all possible variables of life. IE: walls are hard, concrete is hard, etc etc. Say you have one ‘mind’. this mind is linked to a database where everything is stored (the properties of life, like walls = hard, pillows= soft, etc). this mind is a database in itself though, and it has things stored in it, and as this mind learns, the database stores the information. one thing that would have to be overcome is the collection of null values. if you are a young child, you may learn eventually that the wall is hard, but you may not know what the wall actually is. so you would have a field in the mind’s database that says ‘is hard’ (which would be another one of life’s properties), and have that link up to a null value because the mind doesnt know what to call the ‘hard thing’. someone would have to tell the mind what a wall is, or what the hard thing is. so then the mind’s database eventually grows very big with null values, and non-null values. if you think about it, the human mind works in a similar way. you have a bunch of information in your mind that is either known or unknown, linked or unlinked. wall is linked to ‘is hard’ and vis versa. for example, i know that there is a sky, which has many different properties. begin stupid metaphors it is blue, its full of air, clouds, etc etc. maybe you know there is a thing that is blue and has air and clouds, but you dont know the name. maybe you know something has clouds and something (which is air, but you dont know what air is), but you dont know what that said thing is. you can think of the mind as a giant file system. if you have ever seen the movie Dreamcatcher, think of the part where the main character is in his own mind, and he can move the memory files around, etc. this filesystem is the mind itself. everything a mind knows is stored in the filesystem. a mind can not know something and not have it in the filesystem.
if im getting complex, sorry, im trying to put this into some kind of readable form :).
continuing on,
so the giant database exists for all the midns who link up to it. similar to the matrix, lots of people hooked in, their minds linking up to a giant database. this database has an unfathomable number of global variables like ‘rocks are hard’ ‘bouncyballs bounce’ etc etc. i will refer to these variables as ‘knowledge’, and i will refer to this large database as the ‘world’. now, if our ‘mind’ links up to this ‘world’, it begins to live, and learn. over time this mind acquires parts of ‘knowledge’. one thing about the ‘knowledge’ is that if you have a rock, rocks have many attributes. like, a rock is hard, a rock can be shiny, a rock can be dark, can be light, etc etc… (thus creating a HUGE database that is the ‘world’) there are many different forms of rocks as well. so then you would have trillions upon trillions upon trillions of little databases that are the ‘knowledge’, such as rocks again. a rock would be a database of its own, containing ALL of the possible attributes of a rock. the ‘mind’ will know many different parts of the rock. this mind holds much information, and starts to form a ginormous database of its own, creating mini databases for rocks, for walls, for bouncyballs, etc etc. now this mind has lots and lots of information about all sorts of different things like rocks, walls, and bouncy balls. (hehe, that rhymes). as the ‘mind’ ‘lived’ and grew and expanded, it would apply this knowledge to its actions. ie: dont run up as hard as you can against the wall, because it hurts. i will cover feelings further down on this post. now we have a mind that starts to think on its own, learning things like walls are hard, bouncyballs bounce, bob marley is god, rocks are hard, and so on. this mind continues to gather more information from this ‘world’ database, as it experiences different things from the ‘world’ and its objects (ill explain objects later). the term learning can and must be broken down, so that it is possible for someone to have the mind learn. learning is pure experience. without experiencing something you can not ‘learn’ it. you can not know what 1+1 is without actually doing 1+1.(even if you see 1+1 being done,you would most likely try to figure 1+1 out, thus forcing your mind to experience what 1+1 is) this is another thing that makes AI complex. not everything someone experiences makes them learn. in more rare situations, some things are ignored rather than learned. teaching does not always make the mind learn, for the mind is not always experiencing, only hearing, or even seeing in some cases. objects: things in the ‘world’. these objects have many different attributes applied. an example of an object and its attribute would be a rock and the attribute ‘is hard’. there would be a ginormous amount of objects, and even more attributes. i probably covered this a bit, but this is just for clarity. also, an object doesnt have to be a physical thing, it can be an idea as well. (not going to explain that, too in depth) feelings: the different things a ‘mind’ experiences in the ‘world’. feelings are something that the mind is influenced or affected by. different objects can affect the mind’s perception of other objects, etc. not only will the mind have ‘knowledge’ now, it will also have a whole database of feelings and emotions. this database of feelings and emotions will grow as the mind experiences different things, like running into a wall, and feeling pain, and having an emotion of sadness, anger maybe. back to feelings…
feelings can be triggered by anything in the ‘world’. things like a flower making the mind feel happy, or death making the mind feel sad. while the objects in the ‘world’ may have constant attributes, the mind will interpret things differently. a rock to one mind may make it feel mad, while a rock in another mind may make it feel happy. say there is a master database of emotions, and in this database, EVERY single possible emotion is stored here. the ‘mind’ will acquire these emotions, and attribute them to objects. if you get beaten with rocks all your life your mind will hate rocks, and attribute a negative emotion to rocks. basically, one mind’s interpretation of an object will most likely differ from another’s. this is the reason that ‘objects’ can not have emotional properties. objects are things in the world, and emotions are the mind’s interpretation of these objects. then once the mind attributes an emotion to an object, this emotion is stored within the mind, and will have an effect on other objects and other emotions. another complexity exists. the mind can attribute emotions to variations of objects. ie: a shiny rock makes a mind feel good, and a dull rock makes the mind feel bad. <— simple terms. this creates the mind to also store different instances of objects, all with emotions attributed to them. (another huge database).
although i did not cover every aspect of a human mind, i am not educated enough to know every single thing. heh, they dont teach you about such things in 11th grade.(to my dissapointment)
well, my brain is fried, im going to work on my website now :), I hope this was helpful to your project. Sounds interesting, i might have to chip in from time to time.
LostProfet
“Imagination is the only weapon against reality”
ps: longes post ive ever made heh
{EDIT} also, i probably contradicted myself or something, i was writing from my mind, and i didnt pay much attention to sounding smart lol {/EDIT}
Correct me if I’m wrong… but isn’t this what we’ve been talking about this whole time (but further detailed)? Or have I just gotten the wrong idea:confused:?
Really good stuff LostProfet, makes me think about a lotta stuff
“Why do I hate alcohol?”
“Oh yes, it was my father’s excuse of beating the tomato juice out of the family.”
I’m in 11th grade too =)
Anyway, how I’ve seen it so far:
A child does not know to jump of a table falling face first if it doesn’t know gravity pulls it towards the ground, and since the ground is hard… well…
Anyway, we, as humans, are also an animal (scientifically speaking I suppose), and so we have some natural senses. Somethings we just know NOT to do (though I can’t really think of anything humans wouldn’t do when they’re still at an infant stage, at least after watching America’s Funniest Home Videos).
The mind explores often through curiosity and so we should have a curiosity variable. The more curiosity, the more things Ayumi wonders about, the more things she wonders about, the more she explores about them. This may be a good and/or bad thing, however. Putting her hand on the hot stove may not be the best idea.
So much more to say… but…
I think we should just stick with the basics for now, then add on more and more, like layers of memories… yes, I DID want to sound ‘wise’ for just a moment
We should begin on the simple emotions such as happiness, sadness, anger, ect. The same goes for her world. We could start with one room, maybe the living room, and create it so she is able to interact with the objects in the room. Place some simple objects in the room. A toybox containing a ball, a fish tank containing water, and maybe a flower pot with dirt and small pebbles and such.
Once we can make it so that she’s able to explore, identify, and learn all about it, we can expand her world. Create the whole house. And in a bedroom, maybe we could make it so she likes a certain color based on what color you keep your walls, carpet, tissue box, or dislike it because she’s gotten sick of it. We could base that off her curiosity level, the higher it is, the more different colors she may want to see and so gets sick of colors quickly. Anyway, in that room, we could have different colored clothing or just simply purple slippers. In this bedroom, she learns about clothing, realizes the colors she like (though not constant), and what things she uses and what others she wears instead of using.
A little by little, we could make it so she even has a mall she goes to, a grocery store ect.
I’m not too sure why i’m saying all this, I’m pretty sure that’s how it’s been in you guys’ minds as well, just been really tired and really just… wiggin out and stuff.
Sorry if I said something stupid (though may be this whole post, haha)
Hurray for us!!! We’ve got the thread with the most views :p:
I’ve put togeather some really quick, basic, and (at the moment) useless scripts.
Everything here is basically the registration, login, forgot password etc etc etc.
So far I’ve only got it in PHP so those of you without servers that support PHP, you might have to ask a friend to load this stuff onto their server.
These scripts are safe however no one here, nor myself will be held responsible for any damaged caused by the original scripts OR modifications to the original scripts. On using these files, you are doing so at your own risk.
The above is just so no one can sue anyone.
Here they are
config.inc.php
<?PHP
$dbhost = "localhost"; //Database host name....can be left as localhost
$dbuser = "username"; //Database login username
$dbpass = "password"; //Database login password
$dbname = "database_name";//Name of database
//for linux users it would be "username_databasename" e.g. "bob_work"
//for solaris and unix users it would be "website_com_-_databasename" e.g. "bob_com_-_work"
?>
connect.inc.php
<?PHP
include_once('config.inc.php');
$connect = mysql_connect($dbhost, $dbuser, $dbpass) or die(mysql_error());
$select = mysql_select_db($dbname) or die(mysql_error());
?>
install.php
<?PHP
include_once('config.inc.php');
if (mysql_connect($dbhost, $dbuser, $dbpass))
{
if(mysql_select_db($dbname))
{
if (mysql_query("CREATE TABLE `ai_users` (
`username` VARCHAR( 20 ) NOT NULL ,
`password` VARCHAR( 20 ) NOT NULL ,
`email` VARCHAR( 50 ) NOT NULL ,
`id` INT( 10 ) NOT NULL ,
PRIMARY KEY ( `id` )
);"))
{
echo "<center><B><U>Database has successfully been installed!</U></B></center>";
}
else
{
echo "Error!
Please check that you do not already have a table named 'ai_users'.
Click <a href='" . $_SERVER['PHP_SELF'] . "'>HERE</a> to try again.";
}
}
else
{
echo "Error!
Please check that the database name in 'config.inc.php' is correct.
Click <a href='" . $_SERVER['PHP_SELF'] . "'>HERE</a> to try again.";
}
}
else
{
echo "Error!
Please check that the username, password in 'config.inc.php' is the correct login for your database.
Click <a href='" . $_SERVER['PHP_SELF'] . "'>HERE</a> to try again.";
}
?>
register.php
<?PHP
include_once('config.inc.php');
include_once('connect.inc.php');
$username = $HTTP_GET_VARS['username'];
$password = $HTTP_GET_VARS['password'];
$email = $HTTP_GET_VARS['email'];
$id = rand(100000000,999999999);
$check_usr = mysql_query("SELECT * FROM ai_users WHERE username = \"$username\" ") or die(mysql_error());
$check_result = mysql_num_rows($check_usr);
if ($check_result > 0)
{
echo "&result=2&"; //username in use!
}
else
{
$query = mysql_query("INSERT INTO ai_users(id, username, password, email) VALUES
(\"$id\", \"$username\", \"$password\", \"$email\") ") or die(mysql_error());
$confirm = mysql_query("SELECT * FROM ai_users WHERE username = \"$username\" AND password = \"$password\" ") or die(mysql_error());
$result = mysql_num_rows($confirm);
if ($result > 0)
{
echo "&result=0&"; //Everything is ok!
}
else
{
echo "&result=1&"; //Error!
}
}
?>
login.php
<?PHP
include_once('config.inc.php');
include_once('connect.inc.php');
$username = $HTTP_GET_VARS['username'];
$password = $HTTP_GET_VARS['password'];
$query = mysql_query("SELECT * FROM ai_users WHERE username = \"$username\" AND password = \"$password\" ") or die(mysql_error());
$result = mysql_num_rows($query);
if ($result > 0)
{
echo "&result=0&"; //Everything is ok!
}
else
{
echo "&result=1&"; //incorrect username or password
}
?>
password.php
<?PHP
include_once('config.inc.php');
include_once('connect.inc.php');
$email = $HTTP_GET_VARS['email'];
$query = mysql_query("SELECT * FROM ai_users WHERE email = \"$email\" ") or die(mysql_error());
$result = mysql_num_rows($query);
if ($result > 0)
{
$row = mysql_fetch_array($query);
$username = $row['username'];
$password = $row['password'];
$subject = "AI password recovery";
$message = "Dear " . $username . ",
I have sent you this email because of a request from the AI program.
If this email was not sent by yourself, I suggest you change your email in the database.
The following are your login details:
Username: " . $username . "
Password: " . $password . "
Have a nice day :)
From your friendly AI server.";
$sender = "PasswordRecovery@" . $_SERVER['HTTP_HOST'] . ".com";
mail($email, $subject, $message, "From: " . $sender);
echo "&result=0&"; //Everything is ok!
}
else
{
echo "&result=1&"; //Email not found
}
?>
I have attached a zip file with all the php pages and the fla that goes with it. You will also need to go through the fla and change any links in the code to the path of your website. If anyone has any problems, please ask a friend because I havn’t got time to help out everyone personally. I’m sure there will be bugs but nothing dangerous so theres no need to be paranoid…unless your using an illegal copy of Flash :jail:
:to:
Please make sure that you change ‘config.inc.php’ to have your server’s username and password rather than the text that is already there.
For example…if my database user and pass is “OBCT” and “IgotApassion4Flashin” you would use this…
<?PHP
$dbhost = "localhost"; //Database host name....can be left as localhost
$dbuser = "OBCT"; //Database login username
$dbpass = "IgotApassion4Flashin"; //Database login password
$dbname = "OBCT_aiDB";
?>
Now this is where the hard stuff starts :thumb:
We’re just about to get into the actually AI side of things. From here on, we’re going to need ALL the help we can get.
The graphics on the fla file I attached are s*** so anyone is welcome to come up with some design to use or edit anything they want.
Important Note:
The form style components were…
Created by N G Rohler.
Email: theelk@elkfoot.com. All rights reserved.
Doing all the AI scripts is probably going to take months. So PLEASE HELP!!!
Even if its just formulas and algorithms copied and pasted from this forum and into Flash, it will still help.
http://www-cs-students.stanford.edu/~amitp/gameprog.html
This is a link that has other links to HEAPS of information on AI. We won’t be doing alot of the advanced stuff because most of it is based on game programming rather than AI programming. Anyhow, it will still give everyone a better understanding of how AI works, how to implement it and all sorts of other stuff you probably dont need to know
This won’t work without Team Work!
Please help us all out
I’ve got a busy 2 weeks coming up but I’ll be doing all I can to contribute to the project.
Cheers :thumb:
ma bad…we’re the 5th most read post.
Nice submission, everyone… we’re getting into some deep metalogical territory here… heh heh…
Some things:
l0stpr0fet: Sounds about the same as what I was thinking. The trouble here is that it will be hard (if not impossible) to 100% accurately reproduce the human psyche, if nothing else because of the difficulties in the fact that the computer does not have anyway to understand physical things. How would you describe HOT or COLD, or PAIN to a computer? I think what we are all trying to acheive here is to emulate a very simplistic version of a Human Mind, in a laboratory environment. She won’t have access to certain emotions, or things, but I deffinately agree with the fact that she should be able to create her own connections between objects and emotions. If we show her a candy bar, and she eats it, and the candy bar has a Taste (example) value of 99, then she may decide she likes te candy bar, and eat them often, to raise her happiness… but if we smack her everytime she eats a candy bar, she may decide that she doesn’t like them all that much, and may even become a bit of a chocophobe… which would be a little crazy… :beam: I hope you decide to stay with the project, and lend a hand!
Spirit-Z3RO: I was thinking along the same lines of your Curiosity thing… :beam: Hopefully we can get to a point that even if we’re not even there, she can still be learning stuff on her own, which would be awesome! Say we leave her alone by herself, and she starts to get hungry. We’re not there to feed her, but she sees the fridge in the kitchen, and her curiosity drives her to open the door… and viola! Food! After that, our main problem will be to keep her from getting a little too much overweight…
OBCT: You know a lot more about PHP than I do… :beam: I’ve only dabbled! I promise to have a server running for us shortly, just bear with me (getting a check on friday, so I can get it going by the end of the month…) I’ll be running the latest version of Apache, and will be able to run PHP on it with no problem, and I have MySQL as weel. I’ll plug in the files you posted earlier. I’ll send you out a PM when everything’s going on Authentication instructions, and so on. Alternatively (and probably better for my bandwidth), we can pitch in and spring for some hosting with another provider. DotEasy.com is afforadble, and pretty reliable, but we should all pitch in, and I’m not sure if we all want to do that, just yet…
Great work everyone! This is building up to be an awesome project! I’ll post some more technical info later on… :beam:
wow this proyect will be very complicated!
anyway i read some of ur posts and i imagined it with some kind of isometric system, if u know how to do this well u could randomly build houses for ur characters with personality AI and even make a house editor! that would be cool
Just a quick update for everyone…
I’ve found a good script to use as a base but it’s going to need alot of work.
This was made by
Chad Adams
adams_chad@yahoo.com
[AS]
#initclip 3
function ChatBot()
{
this.callbackHandlerLocation = this._parent;
Key.addListener(this);
this.init();
}
ChatBot.prototype = new MovieClip();
ChatBot.prototype.setCallbackHandler= function(method, location)
{
this.callbackHandlerLocation = (location == undefined) ? this.callbackHandlerLocation: location;
this.callbackHandler = method;
}
ChatBot.prototype.onKeyDown = function()
{
if(Key.isDown(Key.ENTER))
{
this.findAnswer(this.input_txt.text);
this.output_txt.scroll = this.output_txt.maxscroll;
this.input_txt.text = “”;
Selection.setFocus(this.input_txt);
}
}
ChatBot.prototype.say = function(the_str)
{
this.output_txt.text += the_str + newline;
}
ChatBot.prototype.init = function()
{
me = this;
this.my_xml = new XML();
this.my_xml.ignoreWhite = true;
this.my_xml.onLoad = function(success)
{
if(success)
{
var root_xml = this;
while(root_xml.nodeName == null)
{
root_xml = root_xml.firstChild;
}
me.dataObj = new Object();
me.createObject(me.dataObj, root_xml);
Selection.setFocus(this.input_txt);
}
else
{
this.output_txt = “error loading xml”;
}
}
this.my_xml.load(this.the_file);
}
ChatBot.prototype.createObject = function(theObj, the_xml)
{
for(var i in the_xml.childNodes)
{
if(the_xml.childNodes*.nodeValue == null)
{
var obj = theObj[the_xml.childNodes*.nodeName] = new Object();
this.createObject(obj, the_xml.childNodes*);
}
else
{
theObj[“text”] = the_xml.childNodes*.nodeValue;
}
}
}
ChatBot.prototype.findAnswer = function(the_str)
{
the_str = this.shaveChars(the_str);
var my_array = the_str.split(" “);
var firstFound = null;
my_array.push(“text”);
var pos = this.dataObj;
for(var i = 0; i < my_array.length; i++)
{
if(pos[my_array*] != undefined)
{
pos = pos[my_array*];
if(firstFound == null)
{
firstFound = my_array*;
}
}
}
if(pos.length != undefined)
{
var text_array = pos.split(”|“);
for(var i = 0; i < text_array.length; i++)
{
var n = text_array*.lastIndexOf(”:");
if(n >= 0)
{
var x_str = text_array*.substr(n+1);
this.execCallback(x_str);
}
else
{
this.output_txt.text += text_array* + newline;
}
}
}
else
{
if(firstFound == null)
{
this.output_txt.text += “Sorry, I don’t understand. Please ask questions only.” + newline;
}
else
{
this.output_txt.text += “I don’t know “+firstFound+” that is.” + newline;
}
}
}
ChatBot.prototype.shaveChars = function(the_str)
{
var chars_array = new Array(“.”, “?”, “,”, “!”, “'”);
for(var i in chars_array)
{
var str_array = the_str.split(chars_array*);
the_str = str_array.join(“”);
}
return the_str;
}
ChatBot.prototype.execCallback = function(the_str)
{
this.callbackHandlerLocation[this.callbackHandler](this, the_str);
}
Object.registerClass(“ChatBot”, ChatBot);
#endinitclip
[/AS]
In a nutshell, this is a script that loads and parses an XML file that contains things for our AI character to say.
<person>
<how> I am well thank you </how>
<OBCT>The coolest Flash Application Developer alive!!!!</OBCT>
</person>
This xml file for example, will use “how” and “OBCT” as key words, search through the list and find a keyword, then return the node value.
If we ask
Who is OBCT?
The application will return
The coolest Flash Application Developer alive!!!
I’ve attached this extension for anyone to experiment with.
Cheers
Where can I go to learn the basics of PHP (don’t even know what it stands for…).
Hmmm… still need a formula for a few things -_-
Do we want to speed up the days of Ayumi’s world, or are we going to keep it the same as real time?
If we do decided to speed up her day, there are only a few times you can speed it up to keep the seconds/minutes/hours to be a clean number (as in not 2.3333333337 hours per day).
We can speed the time up for the clean numbers by 2, 4, 6, 8 and 12.
so
24 hours / 2 = 12 hours - 12 hours per day
24 hours / 4 = 6 hours - 6 hours per day
24 hours / 6 = 4 hours - 4 hours per day
24 hours / 8 = 3 hours - 3 hours per day
24 hours / 12 = 2 hours - 2 hours per day
There’s advantages to both of them, but I don’t have time to post them, so I’ll just wait till what you guys think of it all.
And the learning/memory and curiosity… if her curiosity is intensivly high… which makes her wanting to explore rather than sleep… her learning ability and memory would be a bit lower for that time when she should be really tired as we would be if we didn’t sleep.
Sometimes we go to bed still wondering about some things, but we can wait because we’re satisfied with what we’ve found out about what we’re wondering already… so basically…
we need a satisfaction variable!..
…
I think…
http://www.phpfreaks.com/
http://www.phpbuilder.com/
Theres plenty of tutorials there but don’t go out of your way to learn something if your not interested in it.
I’ll just keep in mind to comment my (other peoples) code more often.
Spirit: Good point, but I think we need to think about it a different way… perhaps a Will variable? And come up with some kind of algorithm such as this:
(Bear with me, since I pretty much forgot what variables we came up with before, but this is hypothetical, anyway… :))
if ( (.energy + ((.will + .drive)/2) + (.curiosity/4)) + (.mood/2) > 0 ) then NeedSleep = False;
We’re going to end up with tons of things happening every interval, I hope that we don’t run into a processor problem, i.e.: too much code happening at one time… another good argument for using simple, non-processor intensive graphics…
So here’s a general layout of the way the program will (possibly) run:
[list=1]
[]Program Start - Establish link to Databases, and open beginning scripts.
[]Draw Graphics - Begin assembling the graphics, i.e., the house, the objects, etc.
[]Establish Current Environment - Take current time/date, and take random factors, to build the evironment: Temperature, weather, etc.
[]Awaken Ayumi - Give Ayumi all the needed info she needs to function.
[]Run Check - Checks all of Ayumi’s current status… i.e.: hunger/mood/etc.
[]Free Run - Give Ayumi the ability to do whatever she wants, and let users interact.
[*]Check Back - Every X intervals, go back to step 5.
[/list]
We’ll need to disect each of these steps as we go along… personally, I think checking her status every second or more often is a bit much, we could try to move it back to about once per minute, or once every 30 seconds… depending on the system.
I don’t think we should try to speed up her local time, we should keep it real-time, based off of the Server’s Time. So that 9:00 Pm server time would be night-time to Ayumi, and she’ll act acordingly:
if (night) then
EnergyDrain = 2
else
EnergyDrain = 1
end if
So that she gets tired quicker when it’s night time…
We can make a lot of other similar ‘quirks’, like, if it’s raining, her energy and mood decrease exponentially. Things of that nature.
When we display her ‘world’, we should split the screen into 3 sections:
[list]
[]**Main Environment - **Shows Ayumi, and her environment
[]**Status - **Shows all of her stats, and things, in easy-to-read bars. Perhaps we can/should make it toggle, so that you can hide it if you want…
[*]**Actions - **Quick Icons to show things that the user can do. Talk, Pick Up, Examine, etc.
[/list]
We’ll have to come up with a list of Actions that we (the users) can perform, and what they do… I named a couple, but I think we can make up a lot more, if we want.
We still kinda need someone to do all the graphics for Ayumi, and the animation… if anyone is interested in lending a hand, but is more Graphically oriented…
[
[list=1]
[]Program Start - Establish link to Databases, and open beginning scripts.
[]Draw Graphics - Begin assembling the graphics, i.e., the house, the objects, etc.
[]Establish Current Environment - Take current time/date, and take random factors, to build the evironment: Temperature, weather, etc.
[]Awaken Ayumi - Give Ayumi all the needed info she needs to function.
[]Run Check - Checks all of Ayumi’s current status… i.e.: hunger/mood/etc.
[]Free Run - Give Ayumi the ability to do whatever she wants, and let users interact.
[*]Check Back - Every X intervals, go back to step 5.
[/list=1]
With number 1…we’ve got a good start :thumb:
To have this finished we’re going to need to have set as many of the constant’s as possible, or at least which one’s we’re going to use.
Number 2…I’m graphic illiterate, so I’m not even going to go there :sigh:
Number 3…Lets give this a start! If we use maybe 4+ variables such as
-Wind
-Precipitation
-Temperature
-Humidity
Using that we can figure out a random number between x & y, then have that change every z minutes. It shouldn’t be too much of a problem because we don’t need anything else to have been made.
Let me know your ideas and we’ll take it from there.
Number 4 and down…we’ll keep throwing ideas around then put it togeather when we get up to it.
We’re going to end up with tons of things happening every interval, I hope that we don’t run into a processor problem, i.e.: too much code happening at one time… another good argument for using simple, non-processor intensive graphics…
SeiferTim, your exactly right! Good thinking! :thumb:
Graphics and moving objects (usually) eat up the most processing time so here’s a few ways of getting around them
- Attaching images and movieclip objects dynamically so we’ll have the option of deleting it when its not in use
- Using…“non-processor intensive graphics…”
- Not using Flash :to: jks
Oops, 3am…I got work in 5 hours :hangover:
Keep up the good work everyone
Cheers
Think, think, think… c’mon brain! WORK!
Okay. Weather.
Someone else can come and clean up my sloppy code, since I’m doing this while I’m at work… I know it’s not syntaxically correct. Shoot me…
[AS]
//basic global variables for Weather conditions
Temperature:Number; //Temperature in degrees
Humidity:Number; //Amount of Humitidty (if it’s anything like St. Louis, it’s be up as high as it can go… )
Precipitation:Number; //Percentage of current precipitation, low (like say 10) is light drizzle, or light snow flurries, 100 would be like torential downpour, or blizzard.
Wind:Number; //windspeed in MPH
Conditions:Number; //Percentage of how favorable the weather is in general (100% = Perfect, 0% = DO NOT GO OUTSIDE!!)
precipType:String; // type of precipitation that wil occur…
//basic code snippits for actual weather conditions… add them into the code somewhere to give the weather some change…
if (Temperature > 35) {
precipType = “Rain”;
} else if (Temperature > 32) {
precipType = “Sleet”;
} else {
precipType = “Snow”;
}
Conditions = (100 - (Precipitation + Wind + (Humidity - 20))) + (Temperature / 4); // I think this needs some work, but this is kind of a sample…
[/AS]
Anyone care to add to it?
SeiferTim,
I think for an AS based character with a database to draw upon, you have a good begining to an algorithm there. I think the important thing is to remember the KISS rule. While we are thinking about this, we are coming up with new ideas, but when thought out, we will find that most of them are variations on a theme. Much like optimizing any set of code, our algorithm will begin to grow complex, but eventually will be able to be optimized to an AS compatible form.
One thing I think we need to add now is the environmental variable of the desire objects. Perhaps we can say that if the current environment is the restroom (or any environment that would make eating undesireable), the desire for any food object would diminish. However, upon leaving the restroom, it would would increas by an amount that is determined by the environment outside the restroom. For instance, the desire for all foods is diminished by 70% upon entering the restroom, and upon leaving the restroom, it returns to the previous level (with a time factor), unless events have passed in the restroom that would prevent it (won’t even hypothesis on what events ). If the environment outside the restroom has changed upon leaving it, say someone opened the oven with chocolate chip cookies making the entire house smell delicious, then the desire would be increased/decreased appropriately. I would like to keep it as simple as possible, but I think this is an important factor.
Spirit-Z3RO,
I’m not certain that curiosity and desire are different. Every intelligent being is constantly in search of knowledge of some sort, whether it is knowledge of what their favorite character on TV will do next (never thought of being a couch-potatoe as a knowledgable experience before eh?), or the knowledge of what a wall is in the eyes of a child, or the knowledge of how to achieve success, it all boils down to an attempt to satisfy a desire. The couch-potatoe enjoys the TV character, and desires to know more about them (is curious about them). The child wants to learn what the wall is so that they can interact with others (a basic desire), after all, they are asking how to say wall, not what is a wall in this example. The hyper-acheiver wants success, the knowledge is just a means to an end with curiosity being the desire to know how. Hmmm, that pretty well sums up what I’m trying to say, isn’t “curiosity” the “desire” to know?
I do like the energy factor, and I’m already trying to think of how to apply the KISS rule to any implementation of a correlation between energy and environment.
On the subject of compiling this in a single location, perhaps a wikki of some sort would be a good idea? I’m not real up-to-date on how to organize online projects of more than three people.
Also, which AS version should we use? I’m partial to AS1 now, but I believe this project may take long enough to consider AS2 only features as usable in the future.
Roomie has to use the phone, more on this later!
Thanks for the welcome!
JerryScript, THANK YOU I was wondering why the connection between Curiosity and Desire came to mind.
Anyway, SeiferTim, OBCT, thanks for the links, I’ll bookmark them for now… so busy -_- my mother just opened a bakery, so i have to help out there once I get out of highschool. Anyway, I can’t find my notebook… where is it… :*(?
One last quick note for today:
Just wondering, anyone ever mess with using various bit formats for affecting variable factors?
Example: the RGB color object. While it’s RGB value is a single number, it’s composition is formed from three factors that each affect the overall output in both individual and grouped ways. Increasing the value of any of the three basic colors will not only increase that color’s dominance, but also the overall brightness.
So our desire algorithm could be based upon a set number of factors (3 for this example: time since last satisfaction, environment, and current base desire level), and any changes to a particular item’s desirability could be made with a bitwise calculation:
// factors using hexadecimal base
function getDesireLevel(item,time,environment){
return(item<<16|time<<8|environment);
}
This code can be expanded to the number of factors desired, and even have a variable number of factors. The tricky part would be determining which factors should affect which next in the bitwise shift.
Perhaps this is a way to achieve the multidimensional freedom from if/else I ranted about in my first posting?
(sidenote- I am proficient with flash/php/ming and will be happy to help with the coding. With ming (see my old basic ming tutes), we can dynamically hardcode any variables/object/etc needed into a swf, this can help to cut down on the number of calls to the database, and reduce the number of needed calculations at any given time. hmmm, I hope we can make use of the SO as much as possible for even more bandwidth reduction.)