Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411196 Posts in 69314 Topics- by 58380 Members - Latest Member: feakk

March 18, 2024, 08:32:38 PM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsCommunityDevLogsKingdoms, a simulator-RPG
Pages: [1] 2 3
Print
Author Topic: Kingdoms, a simulator-RPG  (Read 7023 times)
Pineapple
Level 10
*****

~♪


View Profile WWW
« on: June 11, 2014, 01:33:18 PM »


To start off with something like a disclaimer: Kingdoms is but the latest incarnation of an idea I started developing years ago and have been gradually refining since. It is ludicrously ambitious and, in all likelihood, will never enter a playable state.

Lately I've been examining what it is specifically about roleplaying games that leaves me unsatisfied. The things that strike me most as unpleasant trends are the sorts of things that just aren't practical to change. I want a depth and dynamism of the world that's nowhere to be found - How come NPCs are such static members of the game world rather than simulated persons with interesting motivations? I want gameplay that doesn't revolve around combat. Popular RPGs often have a long list of interesting and unique skills that can be improved through practice, but in the few cases where skills unrelated to combat are present they're rendered useless by the fact there's nothing to really do besides dungeon-raiding. Virtually every RPG FAQ that addresses character builds is going to tell you "Non-combat skills are useless". Tabletops at least keep track of a variety of noncombat skills, but you've got a couple pages of exclusively combat-related skill values compared to half a page of noncombat ones.

I want to challenge the impracticality of those things. My first and greatest goals with Kingsdom are to create a game world where NPCs interact and make things happen with or without the participation of the player, and where violent adventuring is but the most risky and gruesome of a number of different possible playstyles. For now I'm planning to use ANSI graphics, like Dwarf Fortress, because I believe it's the most painless way - for the developer anyway - to portray a game world with the depth of detail I want to achieve.

So I'm starting this devlog to help keep myself motivated and to get some feedback regarding my ideas. As I further develop the mechanics of the game and begin to implement the various pieces of it I intend to post here to explain the progress I've made.

Check out the skills prototype!
« Last Edit: July 03, 2014, 08:30:04 AM by Pineapple » Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #1 on: June 11, 2014, 01:33:30 PM »

To start with I'd like to talk about how I intend to represent game content using external, easily-modifiable files. It's very much impossible for any one person to balance a game the size of what I'm attempting. It's my hope that if the game is ever made playable that its default content will be enough to get people interested. In which case Kingdom would have the greatest possible resource that any unbalanced game could ask for: A community with robust options available to them for modifying the game.

Relationships between objects and data in Kingdom is inevitably going to be excessively complicated. While a simple and commonplace solution such as XML could probably suffice it just isn't practical. I've been developing a syntax for defining data that's space-efficient, readable, and flexible as I can possibly manage. (I've written dozens of parsers of varying complexity before, but would you believe it was only yesterday that I wrote my first-ever lexer?)

The fundamental structure of a piece of data is utterly simple.

Code:
#node[
    field: "value";
];

The complexity arises from the multitude of functionalities that can be introduced. For one, inheritance. The following defines two nodes intended to represent colors. The first node represents green while the second node represents yellow.

Code:
#color Green [
    red: 0;
    green: 255;
    blue: 0;
];

#color Yellow : Green [
    red: 255;
];

This node would represent a darker shade of green by halving the value defined by the inherited color.

Code:
#color DarkGreen : Green [
    green*: 0.5;
];

Furthermore, abstract "classes" can be defined and nested nodes can be inherited and modified. For example, here MobyDick inherits the abstract NavalFiction's reviews, but cheats and assigns itself an extra star:

Code:
$book NavalFiction [
    #review NYTimes [
        text: "It was great! There was lots of water as well as a bunch of fish.";
        stars: 4;
    ];
    #review HuffingtonPost [
        text: "By far the best novel I've read about boats all year.";
        stars: 5;
    ];
];

#book MobyDick : NavalFiction [
    #review ~ NavalFiction.NYTimes [
        stars+: 1;
    ];
];

Through this and other capabilities of the language, game data can be defined in such a way that is easy to parse, easy to write, and easy to maintain. I intend never to find myself searching through all the content to reassign a hundred instances of one value - Instead, every object will inherit the value from a single location.
« Last Edit: June 11, 2014, 01:38:59 PM by _Madk » Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #2 on: June 12, 2014, 12:42:31 PM »

In addition to its diverse wildlife, the world of Kingdom is home to nine sentient races encompassing five distinct physiologies. The first physiology is that of Humanoids, or "softskins" if you don't care for political correctness. Its members are the Humans, Elves, and Dwarves. The second covers the Underlings, "demonspawn" - a misnomer, or "leatherskins". They are the Orcs and the Imps. The third is Lizardfolk, "coldbloods", or "scaleskins", which are Sirens and Wyrms. The final two races, the Golemi and the Minos, possess physiologies unique to themselves.

Humans are said to be the best race to have your back in a fight. They tend to be excellent in melee combat and have a strong sense of honor. Their culture is to pride themselves on living simply, and with a minimum of mystical aid. Humans tend to be very curious and many a specimen has died because they simply couldn't stop themselves exploring that unusual cave.

Elves are renowned politicians and said to be the worst race to have your back in a fight - but the best in a debate. They tend to be fluent in the languages of flattery and deceit, but can be equally so in understanding and loyalty. They're exceptionally perceptive and have a natural talent for archery. You'll never find an Elf who isn't fond of dry, sarcastic humor.

Dwarves have an affinity for nature and magic. Contrary to their stunted physique, they tend to be agile and especially good climbers. In the minds of Dwarves, to participate in a social gathering sober is a major faux pas; a Dwarven party is one place where you will never fail to find an abundance of liquor and recreational drugs.

Orcs are known for their exceptional fortitude and their culture is known for its disarray and instability. While any Orc alone can make for great company with their jolliness and eagerness to please, their relentless competition with others of their race means that hanging around a group ranges from foolish to dangerous. It's no surprise that they scorn leadership and often live in tribes governed through intimidation by warrior-mystics rather than by any formal system.

Imps are a ubiquitously mischevious people who are experts at moving about unnoticed. They tend to be fond of alcohol and Impish pubs are the best places to go when you're intent on having a merry time and waking the next morning with amnesia and a mortal headache. Imps have a powerful natural resistance to magic. Though they like to jest like no other, they're known for facing dire, even hopeless situations with admirable bravery.

Sirens are amphibious lizardfolk with a culture demanding that time be spent on leisure over industry and that family bonds be strong and cherished. Though their settlements (which are usually ruled by elders) may appear primitive, their way with art and magic is uniquely refined. Their lenient sense of modesty contributes to a reputation of being desirable and hypersexual, though in actuality they tend not to be intimate with people outside their race.

Wyrms are large and dwell in caves. Their settlements are usually built close to geothermic hotspots - such as volcanoes and geysers - as it's necessary to sustain their metabolism. They tend to be excellent craftsmen but lacking thinkers. The structures built by Wyrms are seldom small and plain things, they have a thirst for grandiose and oversized architecture. The image of an old Wyrm city embedded in the walls of a great cavern is one of the most spectacular sights the world has to offer.

Golemi are beings of animated earth. They're difficult to harm by normal physical means but it comes hand-in-hand with their lethargy and clumsiness. Golemi tend to dislike violent conflict and prefer to fill the role of thinkers and philosophers. They're known for their fondness of gardening, how strongly they revere tradition, and the peculiarity of their rituals. For example, the Golemi ritual of adulthood is this: A maturing Golem must remain still while a family of birds builds and inhabits a nest upon them and may only move after the hatchlings have left.

Minos are the wise and compassionate old scholars that other races seek for advice and solace in times of turmoil. Minos are shaped like great tortoises and possess an unmatched affinity for magic. While their natural lifespan can range in the thousands of years, it's a custom that many take it upon themselves to venture alone in the wilderness when they grow weary with the world. Sometimes they can be found centuries later, dwelling alone and contented with their isolation. More often it becomes their departure.
« Last Edit: June 13, 2014, 09:48:31 AM by Pineapple » Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #3 on: June 13, 2014, 09:40:34 AM »

Let's see if I can't possibly make one post here every day.

As for progress on the implementation: I've been revising the syntax mentioned before, I think it's going awesome places. I'll probably have another update on it after I've finished writing the parser.

So: What's any RPG without a wealth of weapons and the skills to use them? I'll go into skills in general another time and the novel approach I'm taking with them, but for now I'll explain how I intend to tackle handling weapons in combat. My biggest goal is this: To make the combat mechanics unambiguous and easy to understand while retaining enough complexity to feel as real as possible.

There are seven Melee Combat skills and four Ranged Combat. Here's a breakdown of the Melee Combat skills:

One-Handed and Two-Handed: Any weapon can held in one hand or two. (Or more, if you happen to have them.) Some weapons benefit more from being handled with both hands than others. Many weapons penalize accuracy, damage, and time per strike more when held with just one, and the character's Strength stat is the way to counter such penalties. (A character with olympian strength shouldn't require both hands to swing that puny oversized warhammer, right?) Internally, the way this will work is that every melee weapon would have a Strength requirement associated with it, and having a lower stat would penalize the various aspects of attacking. But holding a weapon in more hands would increase the amount of Strength your character is considered to have for the sake of those calculations.
Martial Arts: More or less the quintessent "Unarmed" skill. I also plan to have a mechanic where characters are able to perform "Maneuvers", like sweeping an opponent's legs out from underneath them, or attempting to disarm them; this skill will have a big impact on the success rate of such Maneuvers.
Bludgeoning, Slashing, Piercing, and Whipping: Every weapon is better at some approaches to offense than others, and these skills allow a character to be more competent in the four different kinds. For example, you'd need a good Bludgeoning stat to use a warhammer effectively and good Piercing to use a spear. The thing about these skills is that they have to be high to take advantage of really good equipment: The lower your stat is in relation to a weapon's skill requirement, the more you're penalized for trying to use that weapon. The end result would be that, with your low piercing stat, you're probably better off using that crappy spear in the corner than trying to make sense of that superamazing spear hung over the fireplace. (In the game, the term for this will be "Competence", or a lack thereof. There will be a clear indication of how competent you are with any given weapon.)

And the Ranged Combat skills:

Aiming: It's one of a few accuracy-increasing skills, but this one primarily affects attacks with ranged weapons. Of the accuracy-related skills, it's best for countering an enemy's high Evasion stat. Where most accuracy skills serve only to temper penalties (of which there are many), Aiming chips away at bonuses afforded by an enemy's nimble feet.
Archery, Arbalism, and Throwing: These skills respectively impact a character's competence with bows, crossbows, and thrown weapons. (But what about slings, you probably haven't asked! Those use the Throwing skill and offer an increase in damage, provided the projectile actually belongs in a sling.)

Now how about the weapons? Here's a culled selection of the various weapons that you'll be able to find or craft in Kingdom: Swords, katanas, pollaxes, rapiers, katars, pikes, tridents, pitchforks, pickaxes, maces, quarterstaffs, scythes, flails, throwing knives and axes, darts, javelins, crossbows, and recurve bows. All should fit nicely into the combat system I've outlined with a minimum of effort, and with more realism to their usage than you'll find in other RPGs. I also have plans regarding just how these weapons show up - it won't be a case of variety overload so much as different cultures in the world having a set of weapons they tend to be most proficient with and consequently own and use. There's an excellent chance that you'd only run into a third or so of all the possible weapons in the game in one world when playing normally. (Though evolution of cultures is a topic for another day, and is one of the more ambitious features on my list.)
Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #4 on: June 13, 2014, 06:23:46 PM »

I made ANSI art. Also it's "Kingdoms" now, because "Kingdom" can't be centered on a normal-size grid of ANSI characters. And because it sounds a bit better besides, maybe. The title has always been a placeholder anyway.



Also, I just finished rewriting the lexical scanner thing to use regex rather than the solution I'd haphazardly come up with before reading up on how normal people handle such things. The first thing would've worked but regex is cleaner and more flexible, so that's what I've gone with. Whew, time to write the actual parser. That's gonna be a piece of work.
Logged
SolarLune
Level 10
*****


It's been eons


View Profile WWW
« Reply #5 on: June 13, 2014, 08:50:33 PM »

Hm, this is really interesting. I'm wondering how you'll handle these NPCs that will have their own motivations and interactions - that seems to be the real meat of the game.
Logged

Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #6 on: June 14, 2014, 03:43:09 PM »

I've got a handful of systems outlined that will hopefully give NPCs some life. I'd like to refrain from getting into detail, considering there really isn't a lot of it - for the moment I'm more concerned about getting the more fundamental parts off the ground - but I think I'll be able to do some really awesome things with the AI. Just for one: I'm working on the details of how to handle memories of NPCs as an estimation of human short- and long-term memory while staying within very reasonable memory and computing constraints. I earnestly think the ideas I have are going to open some unique doors into making a game world feel alive.

And today my topic of discussion will be what happens when someone gets hurt. There are some remarkable and amazing deviations from the generic one-number hitpoint system, the most notable of which is Dwarf Fortress in its representation of every body part. What I want to do with Kingdoms is a little less ambitious than that, but I think it'll be more suitable from a gameplay perspective.

Every creature is made up of several body parts. They can be internal or external, vital or nonvital, they can hold things (e.g. hands), and they can contribute to mobility (e.g. legs). For example, a human might have a head (containing a brain), a torso (containing a few organs), arms and hands, legs and feet. Every part of the body can sustain a maximum amount of damage, represented as a number, before it becomes destroyed, and can only be regenerated by a healer with the appropriate skill. (Of course, destruction of any vital organ is a sure way to bring about a quick death.)

The trick is that the health of a body part is slightly more complicated than its numerical damage. A little damage becomes represented as a superficial wound. A lot of damage inflicted at once becomes an injury. The former will heal over time, effectively regenerating the lost health (albeit slowly), while the latter can only get worse. Another difference is that superficial wounds can be quickly restored using healing magic while injuries require the treatment of a surgeon. (And both sorts of hurts would best be followed immediately by first aid, to ensure they don't become infected.)

Furthermore, every bit of damage done will increase the amount of pain that a character is experiencing. A couple superficial wounds don't do much. But an injury, as a consequence of the associated pain, severely penalizes all of a character's stats. Not to speak of one that's been mauled horribly. Not even the greatest warrior alive can fight with grievous gashes in every part of him. Some poisons and magicks will be able to inflict intolerable pain without physical harm - highly advantageous since enough pain can incapacitate a character or even render them unconscious.

Alchemy is one element of the game essential to anyone who plans to get into many battles, and I want to do something special with the potions in this game. There will still be potions to flat-out restore health like any RPG, but those will require the mystical skills of an enchanter and won't be the easiest thing to get ahold of. Rather, the potions that fighters never go adventuring without will literally be opioids - natural solutions that temporarily relieve pain, reducing or eliminating its debilitating effects so that you can keep on fighting. I intend to take similar approaches with other sorts of potions, too, but those are a topic for another day.
Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #7 on: June 15, 2014, 12:18:04 PM »

I've been working on getting the nitty-gritty of this data syntax finalized and started implementing the parser. Since that's what my head is full of, that's what I'll discuss today.

There are five data types. (Maybe a sixth, if I'm feeling really ambitious.) The five definites are identifiers, numbers, strings, arrays, and nodes. The maybe data type is methods.

Identifiers are pretty much what you'd expect. They can contain letters, numbers, and underscores. (But they can't start with a number.) Numbers are like you'd expect, too. Typical integers and floats. Strings are string literals, things inside quotes. Arrays are just that, arrays, though there's some mutability you wouldn't typically have with an array. Nodes are what really get things done in the language. They're handled like hash tables in some aspects, like classes in others. The important thing is that they're a fantastic way to organize data. Methods, if they happen, won't be for runtime, rather for doing more complicated assignments, like assigning a value conditionally, populating an array with some particular contents. You know, the sorts of things you need proper scripting for.

Here's a simple assignment statement:

Code:

    Foo: "Bar";


Foo is an identifier and "Bob" is a string. The value "Bob" has been assigned to the identifier Foo. That's what everything is based on. There are a dozen different operators, but in the end all of them boil down to being assignments. Here's the second-most fundamental assignment operator.

Code:

    Foo:: "barian";


Where ":" sets a value, "::" appends one. Foo now identifies an array, and its contents are ["Bar","barian"].

One of the biggest challenges has been to come up with a syntax that's both legible and consistent. For example, the syntax for nodes and inheritance has changed from what was shown a few posts back. The new syntax is more consistent with other operators and breaks away from the more jumbled stuff that was present before. It previously imitated common programming syntax, but at the cost of being unnecessarily different from the other assignment operations. The following example creates two nodes, and Child inherits the data from Parent.

Code:

    Parent: { A: 1; };
    Child#:: Parent, { B: 2; };

« Last Edit: June 15, 2014, 01:22:28 PM by Pineapple » Logged
SolarLune
Level 10
*****


It's been eons


View Profile WWW
« Reply #8 on: June 16, 2014, 06:49:25 PM »

That's cool. I'd think "+name:item" might be an easier way to say "append", but it's interesting to see you approaching this from the base level of your own class / scripting language syntax.
Logged

Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #9 on: June 16, 2014, 07:07:36 PM »

It's not a bad idea. I thought it would be best to keep all assignment operators constrained to a self-contained and similar syntax; with very few exceptions every statement is in the explicit format "Identifier Assignment Value". (In fact, I think the only exception is the deletion operator.)

Parsing is coming along well! I've got the basic stuff in place for parsing statements, identifiers, strings, numbers, and arrays. I've still got to do nodes. After that I get to test it and count the bugs. (And there are bound to be a lot of them. What a lunatic I am, designing and implementing a language like this from scratch.)

But I'm sure it'll turn out fine! Durr...?

Like I expressed before, the world of Kingdoms will be presented to the player with pretty simple graphics. But I intend to use that abstractness as an advantage. Every detail about the world will be a detail that players and NPCs can potentially notice. I have some cool ideas about specifically how to present this information to the player, but I'll stick to describing how the perception system will work.

Like any RPG, the proficiencies of characters in Kingdoms are represented by a number of different skills. Like tabletops, there's a very key skill that absolutely mustn't be neglected: Perception.

I want to move away from the traditional diceroll approach of skills - with the exception of things like accuracy and damage in combat - and stick to a system that primarily rewards characters for having skill bonuses sufficient to meet some threshold. For example, various details of the world will be easier or difficult to notice - dependent on factors such as distance and level of light - and a Perception bonus of the proper threshold will reveal that detail to the character. (I also want to have separate thresholds for many details. There will be simply noticing a detail and there will be noticing the specifics. e.g. "Something smells rotten" versus "The wench's undergarments smell rotten"; "The merchant seems displeased" versus "The merchant scowls and speaks tersely".)

All perceivable details are one of five sorts: Visual details e.g. "The orc's muscles are extremely toned", auditory details e.g. "The constable knocks forcefully on the door", tactile details e.g. "Searing heat emanates from the forge", olfactory details e.g. "Something smells of freshly-baked goods", and kinesthetic details e.g. "I'm starving". Perception would have a minimal impact on noticing kinesthetic details - Who can't tell they're hungry? - but you'd better hope some wizard doesn't cast a numbness spell on you. I'm generally looking forward to working with this system as a way to express status effects like blindness and deafness.

A high Perception skill (and levels in other skills that affect perceiving of specific details, e.g. Night Vision with its reduction of visual penalties in low-light conditions) allows the player to paint a much more vivid mental picture of the world they play in, and I'm hoping this system will make the game that much more fascinating and immersive.
Logged
SolarLune
Level 10
*****


It's been eons


View Profile WWW
« Reply #10 on: June 16, 2014, 08:18:38 PM »

Interesting, again. This kind of conceptual and abstract game design is fun to think about. How do you plan on handling someone who has an exceptionally high perception level but that gets stricken with blindness or deafness? Would it just not "take"?

What about if the player gets blinded or deafened - would that influence your display of the game world at all?
Logged

Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #11 on: June 17, 2014, 06:51:49 PM »

I don't suppose a high Perception skill will have any impact on something like a blindness effect. Doesn't matter how good you are at noticing things - if your eyes aren't working then you can't see shit, right? As for how it would influence the display, I imagine the most visible effect of blindness will be the almost nonexistent LOS. As to deafness: I'm intending to include some background music for the game. (Maybe sounds, too, to go along with what the player is hearing, but that would entail handling a lot of assets.) I think it'd be really cool to put a filter over the music when the player's been deafened, make it quieter and lower-pitched.

One of the key groups of skills in Kingdoms is going to be magic. There are four families of magic: Healing Magic, Elemental Magic, Arcane Magic, and Material Magic.

Healing Magic does just what it says on the tin. Associated with it are the Restoration, Regeneration, Curing, Blessing, and Warding skills. Restoration improves a character's ability to heal superficial damage, Regeneration improves their ability to restore destroyed/severed body parts, Curing improves their ability to eliminate hostile effects (especially poisons), Blessing improves the magnitude of blessing spells (which impart buffs) and makes it easier to nullify curses, and Warding improves the Fortitude bonuses given by ward spells.

Elemental Magic is probably the most diverse of the magic skills. Contrary to its place in most games, the first purpose of most elemental spells isn't to deal damage directly, but to affect the world in ways impractical by normal means. You could try setting someone on fire - which isn't as easy as it seems unless you're particularly adept - but you could also try obscuring their vision with smoke, causing them to lose their balance by shifting the ground underneath them, or by heating the air around them enough that they're forced to flee. I have a lot of options I want to make open for the player here. So the actual skills for Elemental Magic are Spellcrafting, Synergy, Fire Magic, Water Magic, Earth Magic, Wind Magic, and Aethereal Magic. Spellcrafting is complicated and will probably get its own post later on to explain. Synergy improves a character's ability to cast spells that combine the elements (for example, frost spells result from a combination of Water and Aetheral Magic; Lightning spells from Fire, Water, and Wind). Fire, Water, Earth, Wind, and Aethereal Magic all reduce the penalties for casting higher-level spells and reduce the mana cost for their respective elements.

Arcane Magic is the sort of thing people will look down on you for. It covers the skills Psychometry, Proselytization, Necromancy, and Cursing. Psychometry isn't to do with spells, instead it dramatically increases a character's effective perception stat as applied to things they touch. More than likely, it will also make it possible to reveal details like an item's creator, its last owner, the number of deaths it's made possible. Proselytization is a tame form of mind control - a character with a high Proselytization stat can manipulate the thoughts and emotions of others. Necromancy, obviously, involves raising the dead. It reduces the mana cost and the penalties inflicted upon raised creatures. (Gonna raise that godlike warrior from the dead with your pitiful Necromancy level? Sure, go ahead! But now he's a shambling zombie without an iota of his original skill. Oh and would you look at that, he deanimated even while I was insulting you because you're not strong enough to keep him shambling for any time at all.) Cursing is the opposite of blessing - it improves the ability to inflict curses and nullify blessings.

Lastly, Material Magic. It includes Enchanting, Alchemy, and Transmutation. I admit this is the least thought-out of them so far. But Enchanting will make a lot of interesting things possible, the ability to enchant skill-fortifying effects into one's armor being one of the more useful applications. Alchemy improves the potions a character makes, and reduces the penalty for using higher-quality ingredients. Transmutation allows a character to transmute one material to another, similar one - e.g. one sort of wood to another, one sort of ingot to another - and having a higher skill decreases the amount of wasted material. (You always get less (usable) mass out than what you put in.)
Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #12 on: June 18, 2014, 11:34:21 AM »

Whoo! Parsing continues to come along nicely. Apart from more thorough testing and likely a couple minor bugs the second layer of abstraction is doing its job. (It goes like this: Text, to tokens, and then to statements.) Now comes actually operating upon data according to the statements, but I don't think that'll be too difficult.

Here's some very simple input/output showing the parsing in action. First the input then the parser's debug-stuff output.

Code:
root: { Field: "Value"; };

Code:
Statement: (token "root" on line 1 byte offset 00000000) (Identifier: (token "root" on line 1 byte offset 00000000) (Value: root)) (Assignment: token ":" on line 1 byte offset 00000004) (Value: [
    Node: (token "{" on line 1 byte offset 00000006) (Statements: [
        Statement: (token "Field" on line 1 byte offset 00000008) (Identifier: (token "Field" on line 1 byte offset 00000008) (Value: Field)) (Assignment: token ":" on line 1 byte offset 0000000D) (Value: [
            String: (token ""Value"" on line 1 byte offset 0000000F) (Value: "Value")
        ])
    ])
])

Yesterday I mentioned Elemental Magic and how you'd be able to combine elements to create other effects. This is all very tentative, but here's what I have so far for different combinations. You can combine up to three elements, and every combination results in a particular sort of magic.

First the basic spell types:

Fire magic generates sparks and can cause things to catch. In general this won't work very well on enemies, since most people aren't so flammable that they couldn't brush the ember off before it can do them harm. Water magic condenses moisture in the air and allows you some command over it. It's a must for anyone who intends to survive long in the wilderness. Earth magic moves rocks and dry dirt, and can be used to mold it into shapes. Wind magic allows you to command currents of wind - create a breeze to lounge in comfort or send a gust to harass your enemies. Aethereal magic makes light, and is a great way to illuminate caves and ruins as you explore them. If you're really good at it, you could generate a beam of light bright enough to dazzle and blind your enemies.

The intermediate spell types, which combine two basic elements:

Vapor magic (Fire+Water) allows you to gather water in the air to create (or disperse) a soothing, if vision-obscuring mist. Magma magic (Fire+Earth) allows you to influence - you guessed it - magma. Won't do you much good when there's no magma lying around, but when there is then ho boy your foes had better watch out. Smoke magic (Fire+Wind) is like Vapor magic, but with two key differences: Where Vapor magic requires reasonably humid air to generate mist, Smoke magic requires nothing special; and where Vapor has no adverse effects on a body, Smoke can cause choking and even suffocation if it's thick enough. Heat magic (Fire+Aethereal) generates warmth without fire, and with enough skill you could dial the heat up to lethal if you wanted. Muck magic (Water+Earth) allows you to exercise control over mud and otherwise waterlogged earth. Storm magic (Water/Wind) allows you to influence the weather - at low skills this might not allow much more than banishing a drizzle, but with admirable skill you could summon hurricanes to batter the fortifications of your enemies. Frost magic (Water+Aethereal) is the opposite of heat magic - it allows you to bring the temperature down. Sand magic (Earth+Wind) is to sand and grit as Earth magic is to rock and Muck magic is to muck. Flora magic (Earth+Aethereal) makes it possible to accelerate the growth of plants, or to cause them to die. Spectral magic (Wind+Aethereal) allows you to make yourself and others spectral (or physical) for a time; spectral beings can't physically interact with physical beings, and visa-versa.

And the advanced spell types, which combine three:

Metal magic (Fire+Water+Earth) makes it possible to move metal, esp. metal objects. With enough skill you could snatch the swords right out from warriors' hands, or simply reduce them to scrap. Lightning magic (Fire+Water+Wind) zaps things with bolts of lightning, of course. Probably the most effective magic types for causing direct harm to your enemies. Temporal magic (Fire+Water+Aetheral) is associated with the common RPG effects like slow and haste. Crystal magic (Fire+Earth+Wind) allows you to move and manipulate crystals. Magnet magic (Fire+Earth+Aethereal) allows you to generate magnetic fields. Low skills might be sufficient to do silly parlor tricks with tiny pieces of metal, but a high competence could make you into a veritable Magneto. Spirit magic (Fire+Wind+Aethereal) allows you to drain or restore a character's stamina. Acid magic (Water+Earth+Wind) allows you to control acidic and basic materials - a mystic with enough skill to make good use of Acid magic and a container of searing acid can do fearsome things to their enemies. Hydration magic (Water+Earth+Aethereal) is unique from Water magic in that the former manipulates existing water while Hydration magic creates it ex nihilo. Feather magic (Water+Wind+Aethereal) allows you to levitate, or even fly with enough skill. Gravity magic (Earth+Wind+Aethereal) allows you to manipulate the pull of gravity in places: Make yourself lighter, and crush your enemies under their own weight.

Of course some elements have more obvious applications than others, but the point of Elemental Magic is diversity. There'll just be so much that you can do when you invest a lot in that skill family.

Decent intermediate and advanced spells will be very hard to get hold of. It entails A) having a high enough Spellcraft skill and enough skill in the constituent basic elements to create your own spells that are worth a damn, or B) finding a mystic far more skilled than you who's willing to sell you their knowledge. (There would also be the possibility of forcing it out of them, but that would be unkind.) As an aside - I think one of the coolest parts of the game will be the economy for knowledge of spells. I have some really neat ideas for that. You could try making money by selling better spells than the local mystic. But then you'll have released the knowledge for the general populace to use and propagate. And are peasants running around with powerful Lightning spells really worth the money earned from sales?
« Last Edit: June 18, 2014, 11:41:30 AM by Pineapple » Logged
qwertyhim513
Level 0
**


View Profile
« Reply #13 on: June 18, 2014, 12:50:09 PM »

I have to admit. This game seems quite complex and interesting. Though when you mention magic  Well, hello there!... does Kingdoms have religion and/or God/deity system? If it does, perhaps consider adding a clerical/religious magic into the game.(Examples being maybe exorcism and evoking assistance)Maybe this "genre" of magic can be expressed or practiced by doing activities like praying and sacrificing. That is if it isn't already part of your healing magic.
Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #14 on: June 18, 2014, 02:07:31 PM »

It's funny you mention it. I intend for gods to be actual characters in the game world - the player can become a god if they're lucky, and if they know what they're doing. It involves a lot of game stuff I've yet to cover here and would prefer to explain on their own terms, but suffice to say it's gonna be really cool.
« Last Edit: June 18, 2014, 08:34:53 PM by Pineapple » Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #15 on: June 19, 2014, 10:20:37 AM »

The second abstraction layer can now make sense of the most devious contrivances I've thrown at it. Such as this one:

Code:
root: {
Field: ["Value1","Value2",{Foo: Bar; Poo: Mar;}];
};

That's two statements inside one node, inside an array (together with two strings), as part of a statement, which is inside another node. Badass, am I right?

Right. Moving on.

The world(s) of Kingdoms will be procedurally generated. I have some ideas about how to do this in general - First you'll generate basic topography, then the game will model the weathering of terrain and abstracted movements and growth of populations for however long you specify. (The length of time will probably tend to be in the hundreds of thousands of years.) Then that'll get turned into actual, tile-based terrain data populated with individual NPCs and creatures. The second stage will be just simulating the world starting from that point, which would be considered the dawn of written word. You could simulate it for anywhere from a few years just to get things settled, to a few thousand to create a culturally matured and technologically competent world you can play in. (Well, as far as medieval-era technology goes, anyway.)

So now you've generated a world, and played in it for a while.

It's only been a couple centuries since the widespread advent of writing. You're one of the great knights of a large fiefdom, but you've aged past your prime. It's time for you to settle down with a comely maiden and stop fighting other men's wars. That you do, and you sire some children. Wonderful daughters, all three of them. But it isn't long before an illness takes hold of your mind and twists your humours until you succumb to madness. your wife kills you in self-defense using your own sword, which you inherited from your father when you were just a boy.

Now you can fast-forward ten or so years and jump back in, playing as your previous character's eldest daughter. And so on.

I intend to allow the player two choices when taking control of a character in the game world. You'll be able to filter all the NPCs in the game world and pick one, at a penalty to the rate at which you level up which increases with the initial level of the character. (There'll be some other restrictions, too - you can't choose a god if you've never become one yourself, can't play a king if you've never risen so far with a previous character, etc.) That basically means that you can start at a higher level, at the cost of gaining further levels being significantly more difficult than otherwise. Or you'll be able to chose any NPC that's a descendant of any of your previous characters with no penalties whatsoever. (Or one you controlled before that's still living.)

I'm hoping this system will cause players to feel genuinely invested in their world. I don't want people ever to feel as though they're just playing as random, disposable characters. They should have an actual legacy, and be encouraged to nurture a world that'll be a better place for their children.
Logged
Quarry
Level 10
*****


View Profile
« Reply #16 on: June 20, 2014, 07:03:14 AM »

This "sounds" like Dwarf Fortress with none of the progress, good luck but prepare to fail
Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #17 on: June 20, 2014, 09:11:04 AM »

Thanks much! It's nice to have someone I can depend on for encouragement.

Time spent coding has mostly been dedicated to reworking specifically how identifiers are parsed (which are actually kinda complicated) and laying down the initial framework for interpreting all the assignments as mutations of tangible data.

I guess now's as good a time as any to talk about identifiers in this language I'm developing, so that's what I'll post about today.

Here's something simple, just to establish the basic principles:

Code:
balls: {
    foo: "bar";
};

In that example, a new value "bar" is assigned to node "balls", where the value is referenced by the identifier "foo". In the next example, we're creating a node that inherits the contents of the "balls" node and then uses the "foo" identifier to concatenate the strings "bar" and "barian".

Code:
bollocks#:: balls, {
    foo+: "barian";
};

Here's another example. Let's say later on we need to reference the "barbarian" value in the "bollocks" node. Since "foo" is in a different scope - not an identifier associated with this new node - you have to use a member reference.

Code:
berries: {
    kung: bollocks.foo;
};

When looking for the node "bollocks" that contains "foo", the parser will first check the other nodes in the same scope as berries for the identifier "bollocks". If it doesn't find it, it'll step up a level to the parent of the "berries" parent. And so on, until the root node is reached. This means that if, for example, "bollocks" was parent to another node "leftbollock", you couldn't reference it in berries with "leftbollock". You'd have to use "bollocks.leftbollock".

Identifiers can also be assigned an index, a list of indexes, or a range, in an array. The next example creates an array and messes with its values.

Code:
finalcountdown: [10,9,8,7,6,5,4,3,2,1,0]; // define the array.
finalcountdown[0]*: 2; // multiply the value at index 0 by 2 (10 becomes 20).
finalcountdown[2,3,5,7]*: 4; // multiply the values at indexes 2, 3, 5, and 7 by 4.
finalcountdown[1..5]*: 3; // multiply the values at indexes 1 through 5 (inclusive) by 3.
finalcountdown[2,4..8]*: 7 // multiply the values at indexes 2 and 4 through 8 by 7.
finalcountdown*: 0.5; // multiply all the values in the array by 0.5.

In addition to referencing values via an identifier, the identifiers of a node can also be assigned aliases that function as substitutes, and can reference more than one value. The next example creates a node with two of its values given the alias "alias", then both modified in the same statement.

Code:
nuggets: {
    hairfactor ~alias: 0.5;
    wrinklefactor ~alias: 0.75;
    ~alias*: 0.25; // multiplies both hairfactor and wrinklefactor by 0.25.
};

Fun fact: You could achieve identical behavior less efficiently like so.

Code:
nuggets: {
    hairfactor: 0.5;
    wrinklefactor: 0.75;
    factors: [hairfactor,wrinklefactor];
    factors*: 0.25;
};
Logged
Quarry
Level 10
*****


View Profile
« Reply #18 on: June 20, 2014, 09:35:54 AM »

Will factors*: 0.25; effect hairfactor or just factors[0]
Logged
Pineapple
Level 10
*****

~♪


View Profile WWW
« Reply #19 on: June 20, 2014, 09:50:00 AM »

Will factors*: 0.25; effect hairfactor or just factors[0]

When no indexes are specified, an operation like that is carried out upon all values in the array. Numbers would be multiplied, strings would be disregarded, identifiers would have the operation carried out upon whatever value they reference, and arrays (meaning an array within the first array) as well as nodes would have all of their values affected.
Logged
Pages: [1] 2 3
Print
Jump to:  

Theme orange-lt created by panic