Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / computer brain

Author
Message
Slayer93
20
Years of Service
User Offline
Joined: 5th Aug 2004
Location: I wish I knew
Posted: 12th Sep 2004 09:39
How can I make a computer have a mind of it's own and play with the player?
Rennekon
20
Years of Service
User Offline
Joined: 7th Oct 2003
Location:
Posted: 12th Sep 2004 09:42
Do you mean Artificial intelligence?, if so, you just have to do a bunch of If...Then Statments. Or a bunch of random stuff.

John "Dark Lord of Angel Destroying Destiny" Pringlebee, maybe?
Philip
21
Years of Service
User Offline
Joined: 15th Jun 2003
Location: United Kingdom
Posted: 13th Sep 2004 01:14
Christian, you have to sit down and work out what a human would do in various situations. For example:

1. see enemy
2. arm gun
3. fire gun at enemy
4. if enemy dies, stop firing
5. if enemy is not dead, keep firing

Then you write code that produces this result.

Cheers

Philip

What do you mean, bears aren't supposed to wear hats and a tie? P3.2ghz / 1 gig / GeForce FX 5900 128meg / WinXP home
BiggAdd
Retired Moderator
20
Years of Service
User Offline
Joined: 6th Aug 2004
Location: != null
Posted: 13th Sep 2004 08:01 Edited at: 13th Sep 2004 08:03
i wonder if its possible to make a program that learns in DBpro? Say u teach it...... U say "Hello" to it....... then it asks "what will be the respons to that? Then u say "Hello" And it will save that respons to a file.

Instead of typing out endless code....... teach the machine...... as if you would a child........ Thats the future of A.I...... Just think how much code it would take to program a computer to deal with every possible situation in the universe........ The program will never be complete.
harggood
21
Years of Service
User Offline
Joined: 9th Apr 2003
Location: the forest
Posted: 14th Sep 2004 09:15
Quote: "i wonder if its possible to make a program that learns in DBpro?"

I made a program like that. It used 2 string arrays, one for the question and the other for the response. When arrayone(1) was asked arraytwo(1) was the answer. You could teach it whatever. It was useful for storing phone numbers

I think, a better way would be some kind of fuzzy logic. There could be multiple responses to any question. The program rates them somehow and selects the most likely answer.
Quote: "The program will never be complete."

-an interesting idea.

Awfuldark Forest
Dot Merix
20
Years of Service
User Offline
Joined: 15th Oct 2003
Location: Canada
Posted: 15th Sep 2004 10:17 Edited at: 15th Sep 2004 10:20
You could do this a lot of different ways.

Let's say you have a couple of very large arrays.

Like Harggood said, i would have 2 arrays.(Think of this as a seperate program then the main one, call it "the editor")

You have array(1) inputting the questions.. so you would type, Hello
This would be stored into array(1)

Right after that you have array(2) inputting the answers... so you would type, Hello, my name is computer or whatever

Once your done completing all of your arrays run through a for next loop and upper$ them(Capitalize all of the questions and answers), you save them to a text file, thus looking something like this

Answersquestions.txt
Hello
Hello, my name is computer

After your done writing that program, you make the actual "AI" program. You load in your text file into arrays.. then when the person types in hello, you compare that to your array. If it's found, you mark the array number, then load in the answer.


One of the problems you'll encounter is the person typing in something different, or spelt wrong. In this case the only thing you can do is perhaps have random messages in this case.

Ie Question. What is your naem
Ie Answer. People really do like me you know.

Obviously, the more questions and answers you add to the list will lower the posibility of people making mistakes and not getting the answer you want to give them.

Hope this provides a little bit of help.

- Merix
Dot Merix
20
Years of Service
User Offline
Joined: 15th Oct 2003
Location: Canada
Posted: 15th Sep 2004 10:20 Edited at: 15th Sep 2004 10:20
[added this to first post] Sorry.. please delete this post.

- Merix
harggood
21
Years of Service
User Offline
Joined: 9th Apr 2003
Location: the forest
Posted: 16th Sep 2004 06:47
Quote: "One of the problems you'll encounter is the person typing in something different, or spelt wrong. In this case the only thing you can do is perhaps have random messages in this case.
"

If the program doesn't find the question in its question array it asks the user for the answer and then saves it for next time.

You could also have more than one answer for a question. The program finds all possible answers and gives the one that occurs most frequently. The user could disagree with the program's opinion, or request further information.

Awfuldark Forest
matt rochon
21
Years of Service
User Offline
Joined: 15th Mar 2003
Location: Canada
Posted: 17th Sep 2004 04:44
check this out if ur interested in that kind of engine

http://www.pandorabots.com/pandora/talk?botid=f5d922d97e345aa1
Philip
21
Years of Service
User Offline
Joined: 15th Jun 2003
Location: United Kingdom
Posted: 17th Sep 2004 06:22
Or go and look at some of the excellent webpages out there on AI.

If you don't want to do that, a good place to start is always gamedev.net or Amit's Game Programming Information.

Google both.

Philip

What do you mean, bears aren't supposed to wear hats and a tie? P3.2ghz / 1 gig / GeForce FX 5900 128meg / WinXP home
CrAzKiDd55
20
Years of Service
User Offline
Joined: 15th Sep 2004
Location: UK
Posted: 21st Sep 2004 17:31
ask Random SKK he just made this perfect AI program. if i had the code with me i would tell you. He can tell you what to do. his e-mail is adamgreig@hotmail.com . Hes also working on an AI which makes more than one answer using rnd command on the q.txt file and the a.txt file.

Peter

Login to post a reply

Server time is: 2024-09-23 00:34:10
Your offset time is: 2024-09-23 00:34:10