Annotated objects which drive behavior
-----------------------------
I think they should, but "learning" can be quite concrete, or quite abstract. One possible way would be to have an "intelligence" or "learning" stat for every NPC, and use that to randomly determine if it can deduce a particular affordance. That''s VERY abstract, but perhaps not as silly as it seems.
1.Are ''uses'' of objects in the code or data domain of the game?
-----------------------------
Data domain, DEFINATELY. Must be, or you end up with a very inflexible system.
2.Is skill for ''Active Objects'' in the code or data domain? Since there is skill in different things what is the bestway to store this?
-------------------------------------------------------------
I''d also put this in the data domain. Skills can change during the course of the typical RPG game. Skills in different things, well, I''m not sure how to store this, but the main skills should be decided beforehand. There could be lots of productive discussion on this topic.
3.''Active Object'' memory? Lets say an NPC has to go get something at its house. How do it know where its house is?
----------------------------------------------------------
Very good question, it''s one that has been bothering me a lot. For certain objects or locations, the "perceptual range" should not count. I think that''s basically what memory should be, an override of the "perceptual range", but I''d have to think carefully about the implementation, or CPU performance WOULD become a serious issue.
4.What PC variables do u see coming in handy? Health, Hunger, Money,Strength...
----------------------------------------------------------
I think the obvious "animalistic" variables/motivations, such as hunger, thirst, energy (you need sleep), comfort (shelter), and perhaps a few higher ones, like wealth, status...
5.Interaction... How is the player going to interact with NPC''s
----------------------------------------------------------
I''m not sure how that would fit in with affordances. Maybe there are some really good uses for affordances here that nobody has explored yet. At the moment, I have no real ideas about it though.
6.How to handle cooperation between NPC''s?
----------------------------------------------------------
See 5.
7.How to handle deadlock situations?
----------------------------------------------------------
See 5. and 6.
quote: Original post by MadKeithV
I don''t really see how that would work, because it implies that every NPC has to know what "reflecting" is, while that is a property of a mirror. To the NPC, it would look like an object is asking it "Can I perform effect 212 on you?".
What I meant was an NPC state variable to be used to answer the mirrors query (or, to be more general, any surface in the game which can reflect, like glass). If an NPC isn''t programmed to know what a mirror is, then the query will fail and the mirror will know to show that object. However the Vampire addition or any character that could possibly become invisible or non-reflective, would be able to respond to a query with their internal state variable of visible /invisible . This state variable can also be modified by outside forces, like the NPC putting on a cloaking field. Even tho visible and invisible don''t really account for just being non-reflective but visible to others, the mirror doesn''t care whether or not others can or can''t see the NPC, just whether it can or cannot.
And Infinisearch, I think the main problem we''re having with your take on the implementation is that it really doesn''t allow for new objects to be added to the game easily. As Madkieth has pointed out, adding a new object in your system would require you to update the NPC code, which means using patches to install objects instead of just downloading the object file and sticking it in a folder.
_________________________________________________________________
Drew Sikora
A.K.A. Gaiiden
ICQ #: 70449988
AOLIM: DarkPylat
Blade Edge Software
Staff Member, GDNet
Public Relations, Game Institute
3-time Contributing author, Game Design Methods , Charles River Media (coming GDC 2002)
Online column - Design Corner at Pixelate
NJ IGDA Chapter - NJ developers unite!! [Chapter Home | Chapter Forum]
Drew Sikora
Executive Producer
GameDev.net
quote: Original post by Gaiiden
If an NPC isn''t programmed to know what a mirror is, then the query will fail and the mirror will know to show that object.
Ah yes, I see... a bit like what I called an "exception rule"... yes that would work!
quote: Original post by Infinisearch
0.Can NPC''s Learn?
They should be able to . Learning is paramount to the NPCs appearing to be intelligent. They can act intelligent easily enough, but for the player to really see it as intelligent, it should be able to remember things the player does (opponent NPC) and where things are and what things are useful, etc.
My method would be rather unrealistic, as it would give the NPC perfect memory, but here''s a quick thought anyways. The NPC stores a list of all objects it has come across and used. The more contact it has with an item, the higher up it gets placed on the list. Note that these items could be pointers to the actual object so at a given time if an NPC wants to try and "remember" where an object is, it can traverse the list and find the link to the object and query the object to find out where it is. The list of items can be only so long so that items that haven''t been used a lot get pushed off the list so that the NPC "forgets". Of course this is just a really, really general idea off the top of my head. I already see a problem with the whole query system because if the NPC queris an object to "remember" where it was an the object has moved, the NPC shouldn''t be able to track it like that, but store it''s last known location instead. Maybe the object can keep a list of it''s encounters with various NPCs so that when an NPC queries it, it looks in its own list for that NPC and where it was when the NPC last encountered it and stuff like that. Oh well whatever, that was all just to get people talking about it. I know it''s really flawed in some places
quote:
1.Are ''uses'' of objects in the code or data domain of the game?
I agree with Madkeith. Hardcoding anything will grant you inflexibility.
quote:
2.Is skill for ''Active Objects'' in the code or data domain? Since there is skill in different things what is the bestway to store this?
data domain. just for added flexibilty and to handle changing values and all that.
quote:
3.''Active Object'' memory? Lets say an NPC has to go get something at its house. How do it know where its house is?
I would say see #1
quote:
4.What PC variables do u see coming in handy? Health, Hunger, Money,Strength...
I think we''re starting to get a bit too general here. That''s okay, of course, but I''d rather answer this question knowing what situations I was programming for.
quote:
5.Interaction... How is the player going to interact with NPC''s
well if we treat the player as an object as well, he then has the potential to instruct NPCs to do various tasks. This works best for "buddy" or "companion" NPCs. The only difference here is the player chooses what messages to send out to the NPC like "cover my six". The NPC could see that as a "help me" message and depending on his connection to the player (was he someone the player just picked up off the street and really has no attachment) can decide whether or not to help him.
quote:
6.How to handle cooperation between NPC''s?
NPCs should be able to identify others with like-interests and maybe add them to a "companion" list. When they query their agendas, perhaps the agenda can be instead a sort of scheduler that takes that buddy list and divvies up the tasks needed to be completed in order for the NPCs to reach the common goal. So like if both A and B were needed to complete C and two NPCs wanted to get to C, the scheduler can assign one NPC to do A while the other does B. Any additional number of NPCs can be discarded or added depending on whether each individual task can take one or more people. So say 4 NPCs wanted to reach C. If shoving a boulder was task A, and setting charges was task B, the scheduler can assign 3 NPCs to shoving the boulder into position while one sets the charges to blow it down a hill or whatever C is.
quote:
7.How to handle deadlock situations?
Don''t understand this one.
_________________________________________________________________
Drew Sikora
A.K.A. Gaiiden
ICQ #: 70449988
AOLIM: DarkPylat
Blade Edge Software
Staff Member, GDNet
Public Relations, Game Institute
3-time Contributing author, Game Design Methods , Charles River Media (coming GDC 2002)
Online column - Design Corner at Pixelate
NJ IGDA Chapter - NJ developers unite!! [Chapter Home | Chapter Forum]
Drew Sikora
Executive Producer
GameDev.net
Any serious AI is data structure driven. Examples include frames, semantic nets, symbolic logic, Prolog, knowledgebases, etc. A hardcoded algorithm then iterates over this data structure each cycle. Data benefits from not being opaque, inflexible, or stuck in the microsecond of what the code is doing. Get as much as possible into data structures.
Regarding an NPC's memory, I was approaching it like this: every turn, perceived objects and objects which the NPC has perceived before (and likely objects the NPC was made aware of upon its creation) suggest their actions to the NPC. It just seems necessary. As Gaiiden said, maybe the NPC can forget about some less significant objects after a time. So, when an NPC is being presented possible actions, the NPC is able to draw upon objects in the immediate area and objects that the NPC is aware of, provided he is willing to go and get the object that he is aware of.
As for organization, I see the object data organized by action. For each object, there are a number of actions. Each action gets its own frame of data with fields defining the action, the goal that can be achieved, who might 'afford' to use it, notice it, etc. The goals of each action chain together so the NPC can effectively plan a sequence of actions and place this plan on its agenda.
Which brings me around to the agenda itself. I still maintain this can be a flexible, dynamic, and powerful planning tool for the NPC which enables him to achieve realistic and effective behavior.
___________________________________
Edited by - bishop_pass on January 23, 2002 5:56:46 PM
"To understand the horse you'll find that you're going to be working on yourself. The horse will give you the answers and he will question you to see if you are sure or not."
- Ray Hunt, in Think Harmony With Horses
ALU - SHRDLU - WORDNET - CYC - SWALE - AM - CD - J.M. - K.S. | CAA - BCHA - AQHA - APHA - R.H. - T.D. | 395 - SPS - GORDIE - SCMA - R.M. - G.R. - V.C. - C.F.
I find the rest of the subjects covered in this thread interesting, but I don''t see how all of this propsed NPC behavior is suddenly made more feasible with the objects-broadcasting-functionality idea.
Sean (who suspects everybody suddenly has a very low opinion of his reading comprehension)
A CRPG in development...
Need help? Well, go FAQ yourself.
"Feel free to utilize Pouya''s cliff." - Fel
Drew Sikora
Executive Producer
GameDev.net
And Infinisearch, I think the main problem we're having with your take on the implementation is that it really doesn't allow for new objects to be added to the game easily. As Madkieth has pointed out, adding a new object in your system would require you to update the NPC code, which means using patches to install objects instead of just downloading the object file and sticking it in a folder
Read my posts, my implementation was a global data store not hardcoding anything. The only reason i posed the questions of data or code domain is because it is the impression I got after reading some posts, and I wanted to clarify what was going on.
The easiest way for me to explain a deadlock situation is an example. 'locking your car keys in your car' - look at it from the perspective of affordances and NPC actions, and u will see why i brought it up. If you don't take it in to account your NPC will either run around in circles or your program could crash from the NPC code continuously adding the same agenda nodes over and over again in a circular fashion.
I am still wondering about memory however. Moreover READONLY memory, which I'll refer to as genetic memory for lack of a better term. Is 'genetic' memory going to be on a per NPC basis or per Class basis? By class I'm refering to farmer, fighter...
The reason I asked about NPC and Player NPC relations is when in a group how do you determine who the 'leader' is? How do you give an NPC commands, and how do they decide whether or not to listen. It relates to affordances because It seems that if you use affordances NPC AI becomes affordance centric. So interactions/relationships with other character must be taken into account in the data structures. In this way intercharacter relationships could be considered affordances. Charisma, Greed, Trust, Ambition and other character attributes could be used to foster relationship in this way.
Oh and Gaiiden where can i get one of those smokin smiley faces?
-potential energy is easily made kinetic-
EDIT- HTML rusty -
Edited by - Infinisearch on January 23, 2002 8:32:09 PM
-potential energy is easily made kinetic-
Relevant Part: A contradiction might occur when an NPC formulates a schedule of events in which a particular object appears twice in mutually incompatible uses. Let''s go to the cellar example, and assume that the NPC has a chair. He wants to escape. That involves getting to the trap door. So he queries objects for the ability to raise him. The chair responds, so he stands on it. Now he needs to push the trap door open. He queries objects for the ability to push, and again the chair responds. Now what?
Irrelevant Part: Any problems notwithstanding, I think this example points out a fundamental difference between programming AI for real agents (robots and other programs which work on real-world objects) and virtual agents (objects which act only on virtual objects). In the real world, there is much that is not known. For a real agent to push something with a broom, it would have to know everything about a broom: it would have to determine that it needed a broom, look for broom-things in its area, etcetera. A virtual agent can have cheats built into its environment to make the job easier.
---------------------------------------------------
-SpittingTrashcan
You can''t have "civilization" without "civil".