From Post-Apocalyptic RPG wiki
Welcome to the idea dump of the programming department!
The Adonthell project has a fairly sophisticated dialog system that is very similar to our own. We should take a look and see what kind of features they implement, and how they deal with dialogs in general.
- Story Games and the OPIATE System: A thesis about using AI techniques to generate plots/stories in a computer game.
- Papers on AI in computer games: A set of links from aigamedev.
When to use a singleton
- Singleton discussion at gamedev.net: http://www.gamedev.net/community/forums/topic.asp?topic_id=560596
- EA programmer on singletons: http://gameprogrammingpatterns.com/singleton.html
- Washu's take on singletons: http://www.gamedev.net/community/forums/mod/journal/journal.asp?jn=259115&cmonth=4&cyear=2005
- jpetrie's singleton article: http://web.archive.org/web/20080501230036/http://scientificninja.com/advice/performant-singletons (original article gone from his blog)
- Taldor's opinion about singletons in Python: Modules behave like built-in singletons, so creating additional singleton classes would make python code unnecessary complex. Based on this Stack Overflow question.
|Please help FIXME: At some point, this idea dump should be fleshed out into a full-fledged proposal.|
Recently, there has been a lot of on-going discussion about how character statistics should be implemented. Below is a summary of the most recent and productive discussions. To get a better understanding of the ideas proposed and see things in full context, it is recommended that you both read the full logs, and check out each implementation.
- Technomage's initial implementation prototype: http://parpg.pastebin.com/httqN3qN
- Taldor's Statistics Level implementation: http://parpg.pastebin.com/TZaYtkza
IRC discussion I
Summarized from this IRC log.
- Technomage on complexity of his implementation
- Ignore the metaclass nonsense - that's just for checking that subclasses met the interface requirements. Only way I could figure to check class attributes
- I wanted to leverage Python inheritance, just to keep the system flexible. So each stat follows a general hierarchy.
- Technomage on the necessity of objects that share state, and those that don't
- Stats need to be instance factories (i.e. classes) to do that, and there needs to be shared state like min/max values (class attributes)
- Well, minimum/maximum values for a particular stat are always the same for all instances. But a particular value for a particular character would differ from all the others
- A python class just seemed to be the natural canidate, since it has both shared state and individual state as class and instance variables
IRC discussion II
Summarized from this IRC log.
- Taldor on Statistic vs Statistic Level
- -> 'Strength' is a statistic, and my 'strength level' is 80
- strength = Statistic('Strength', ...) ; my_strenght = StatisticsLevel(80, strength)
- Taldor on why Statistic Level isn't just an integer
- because it may evolve in certain cases
- or temporary effect may be present
- StatisticsLevel.addExperience() -> to be precise
IRC discussion III
We hashed out actual code in a seperate #parpg-code channel, here's the logs: File:Parpg-code 2011-01-18.txt
And a link to the prototype code: pastebin#ydgMURbJ