190 reputation
8
bio website florian-kraemer.net
location Germany
age 31
visits member for 2 years, 1 month
seen Nov 18 at 13:46

Jul
19
awarded  Popular Question
Feb
11
awarded  Critic
Oct
9
awarded  Supporter
Oct
27
awarded  Scholar
Oct
27
accepted Generic rule parser for RPG board game rules - how to do it?
Oct
27
comment Generic rule parser for RPG board game rules - how to do it?
The reason for this is that programmers.se does not auto link the url properly, the link is misssing the ).
Oct
25
comment Generic rule parser for RPG board game rules - how to do it?
Check this out dandwiki.com/wiki/Base_Attack_Bonus_(Term) but the idea is to be able to implement different rule sets for different game systems. I think I'll need something that describes the game system and then a parser that will understand the game system and its rules and a parser that will run the game actions based on that ruleset.
Oct
25
comment Generic rule parser for RPG board game rules - how to do it?
@Rachel what you describe is dead easy OOP, there even many examples out in the wild that use RPG like stuff as examples to teach OOP. Having these objects and work with them is the easy part, I could build them on the fly based on data from the database. The issue in your approach are the hardcorded rules like GetEnemyCombatStats() whatever this method does would need to be defined somewhere via an UI and stored in a db. Your article seems to be similar to that github.com/bobthecow/Ruler or that github.com/Trismegiste/PhpRules.
Oct
24
comment Generic rule parser for RPG board game rules - how to do it?
It would be easier to save the generated form data serialized and run the parser on that in the language the app is using instead of using another language. But with lua I could - in theory - set vars to lua, eval that script with my set vars and type cast the result, it might be safe this way.
Oct
23
revised Generic rule parser for RPG board game rules - how to do it?
added 1307 characters in body
Oct
23
comment Generic rule parser for RPG board game rules - how to do it?
This sounds pretty static to me and does not allow an user to simply enter/build the required rules in an UI? What you describe sounds more like hardcoded rules. This should be also doable by having a list of nested rules. I do not want to hardcode any rules. If I could do everything in code I would not need to ask that question, that would be easy. :)
Oct
23
awarded  Editor
Oct
23
revised Generic rule parser for RPG board game rules - how to do it?
added 1002 characters in body
Oct
23
comment Generic rule parser for RPG board game rules - how to do it?
Honestly I thought this site is exactly for this kind of conceptual questions while stackoverflow.com is thought for code / implementation problems.
Oct
23
comment Generic rule parser for RPG board game rules - how to do it?
After reading this I think I could simply eval lua scripts for that. The downside here would be that a user has to be capable of writing lua scripts. My personal goal is to write an interface that can be used without programming knowledge, like the rule builder in magento (ecommerce app). Because I want people to be able to add their own rules. I'm not implementing anything commercial, just a tool to let me and my friends enter the rules of RPG system we play on an irregular base and getting back to the rules and to apply them is a pain after some time...
Oct
23
awarded  Nice Question
Oct
22
awarded  Student
Oct
22
asked Generic rule parser for RPG board game rules - how to do it?
Oct
22
awarded  Autobiographer