class StoryEvent : class totplist
{
// char KeyName[40]; // EventName
// int KeyCode; // EventCode
// char Key2ndName[40];// MapInfo
// int KeySourceCode; // Sender
// int UPriority; // UPriority
// int ObjType; // ObjType
// int nID; // nID
};
class ActionEvent : class totplist
{
// char KeyName[40]; // EventName
// int KeyCode; // EventCode
// char Key2ndName[40];// Misc info
// int KeySourceCode; // Sender
// int UPriority; // UPriority
// int ObjType; // ObjType
// int nID; // nID
XPos, YPos; // Where it emanates from
Range; // Effective Range
Duration; // How long it lasts
Target; // Who receives it
}
Looking closer they seem to be related but do different things. Am I missing any other variables?
In relation to Story Events I was looking in Planescape:Torment's quest.txt
[init]
questcount=125
[0]
title=37696
descAssigned=39732
descCompleted=39733
assignedChecks=1
aVar1=Pharod
aValue1=0
aCondition1=EQ
completeChecks=1
cVar1=Pharod
cValue1=0
cCondition1=GT
[1]
title=39734
descAssigned=39735
....
ZoomBoy
Developing a 2D RPG with skills, weapons, and adventure.
See my character editor, Tile editor, diary, 3D Art resources at
Check out my web-site
Edited by - ZoomBoy on 5/26/00 9:03:18 PM
Edited by - ZoomBoy on 5/26/00 9:04:27 PM
Event Processing for AI
In a previous thread here I talked about creating a messaging system. For that I'll need
In my RPG I've got 2 event types to pass to my message system. One is for the story events(Binky has returned the Golden Shovel to the Royal Foo) and the other is for Action events(during Map movement and combat)
Ya the major difference between them(Story vs. Action event/msgs) is putting together the antecedents or necessary conditions for their completion.
With Action messages, they go onto a queue or list and all the current jobs are sorted by priority.
With Story events I need to keep track of them from map to map. Also there are things they need to have and jobs/events to do before a lone event is completed. Maybe a queue needs to be created.
hmmmmmmmmm
ZoomBoy
Developing a 2D RPG with skills, weapons, and adventure.
See my character editor, Tile editor, diary, 3D Art resources at
Check out my web-site
With Action messages, they go onto a queue or list and all the current jobs are sorted by priority.
With Story events I need to keep track of them from map to map. Also there are things they need to have and jobs/events to do before a lone event is completed. Maybe a queue needs to be created.
hmmmmmmmmm
ZoomBoy
Developing a 2D RPG with skills, weapons, and adventure.
See my character editor, Tile editor, diary, 3D Art resources at
Check out my web-site
I think I''ll just do the Action events only until I figure out a way to Sory event checking
ZoomBoy
Developing a 2D RPG with skills, weapons, and adventure.
See my character editor, Tile editor, diary, 3D Art resources at
Check out my web-site
ZoomBoy
Developing a 2D RPG with skills, weapons, and adventure.
See my character editor, Tile editor, diary, 3D Art resources at
Check out my web-site
Probably not relevant, but just a thought: to check whether something is completed, you could have some sort of recursion:
So if every event stores a list of events that must be completed beforehand, you can still just make a single call to Event::IsCompleted() for any given event and that recursively checks all the events it depends on automatically.
bool Event::IsCompleted(){ for (all events that must be completed before this) { // If any one of them is not done yet, this one // cannot be done either, so return false if (!prevEvent.IsCompleted()) return false; } if (other requirements not met) return false; else return true;}
So if every event stores a list of events that must be completed beforehand, you can still just make a single call to Event::IsCompleted() for any given event and that recursively checks all the events it depends on automatically.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement