The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
My model, of course with testing/calibration, will approach over time (at perfect equilibrium), the prices of equivalent exchange 3, reflecting the distribution within the environment and the work required to distribute said resource.
Really, for the user, there is no visible changes other than different trades, that change over time. The trading blocks are essential extensions of villagers or players.
In reality my first series of steps, for the player, we have now touched on nearly everything
1 - A more stable AI system - I need to create a better AI regulation system, that turn's on/off AI's more efficiently and expansively.
2 - Assign "beds" to villagers - Villagers need a home to "live" out of (even if just temporary for mod)
3 - Create chest for inventories associated with villager linked to bed (serve as primary inventory for villager, eventually villagers will have a more robust inventory system)
4 - Create a system where villagers can weight multiple job profitabilities, and select best one.
Then I would like to finalize basic chunk ownership for territory acquisition.
I think that would be most efficient way to begin weaving all these pieces together in a non-arbitrary way
The function shouldExecute() within an AI module is the first stop of the Minecraft polling process, and it's purpose is to provide as quick a way to discard further processing of a given AI routine as possible. The linked example is for an AI routine called EntityAIFindShelterFromRain, inspired by the way citizens in The Witcher ran for cover when it was raining.
The first test is bail on a null pointer, so there's no null pointer exception.
The second test is to bail if it's not raining
The third test is to see if the citizen is already under cover
the shouldExecute() returns true/false telling Minecraft whether to engage the given citizen in further processing.
Beds & Storage
On npc beds, perhaps a recipe that combines a normal bed with a chest and produces a 3x1 model of a bed with an attached footlocker. There could be some indicator of owned vs unassigned beds, perhaps pillow style, or even have two models, one with a pillow and one without.
On owned beds, it would be nice if the player could click to get quick access to that npc's interaction GUI. And on beds that have become unassigned, it could be entertaining to have some historical reference to the last owner, such as "George was killed by Lava."
Creating NPC Beds might even be the method by which the player attracts a new NPC to their village.
Selection of Employment
Need to understand your design for skills before I can make any recommendations. The one on offer is ten generic ranks of skill per npc that slowly shift to that npc's most used skill.
Also, that which the player doesn't experience isn't worth putting too much effort into. An example of that problem is MystCraft, which has an elaborate descriptive language for worlds which gets altered from time to time, but how to use it isn't shared so for all intents and purposes it's wasted effort. The only kind of MystCraft worlds I make are the ones that I can get from random generation plus whatever few tokens I may find throughout the length of my game.
Rollback Post to RevisionRollBack
My five-point rating system: Yay, kay, meh, erm, gleh
The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
AI Loop
Yes - Your insights kind of showed me something that was in front of me the whole time. I will still have an AI "managing" module, but this actually makes decisions based on inputs. This may change the AI state inducing changes in other AI should executes.
Beds
Possible crafting recipe, but I think I will skip that for now and save it for later. I have planned on storing the NPC civ id to the chest, as is already done for proto-locked chests. Therefore an NPC would only sleep in a bed where it owned the nearby chest.
This bed system could provide a more elaborate "inn" system to be introduced, which I have considered. Maybe let beds work for you so to speak (in the job table). And yes, I have had that idea allowing NPC beds that remain unclaimed to induce random NPC "traveler" appearances.
Selection of Employment
I realize my ideas are hazy in explanation but at this point, it can be considered analagous to the model you propose. It just however, instead of having a "constant" or "linear" or "exponential" experience increase, it obeys the previously described mathematics. Additionally, it is kind of a two dimensional system. In one, skills determine numeric and therefore quantitative properties of an action an NPC can perform (speed maesurements, bonus amounts, etc). The other is qualititative, where the skill is influence by knowledge and context. For example, a quarry man can mine stone and dirt, but without a more advanced technology, stone and other ores remain unlocked.
The leveling system, after rethinking the explanation, is a logarithmic increase in experience level, or the effect of experience. In reality, its like flint is worth 100xp, copper worth 10^5, bronze 10^8, iron 10^11, etc. They could never be displayed as number as they are too big, However, if you treat them as logarithms the leveling system becomes familiar, however the intricate relationshiop remains intact (tier 2 flint, tier 5 copper, tier 8 bronze, etc). Additionally, the experience would not be cumulative, but also remember the "average experience per action" (or have some type of list), that recalls if the skill was acquired, with say iron (10^11) or bronze (10^8).
So essentially a logarithmic range. Say bronze apprentice ~10^8, journeyman 10^9, master 10^10, or whatever. And in reality, if using base 10, each step is of course ten times the amount of the prior. So when adding exp, it would seem to someone unfamiliar that they were adding way too much experience, but that is of course the value in experience between copper and iron weapons.
You could make each tier is a different type (novice, journeyman, etc), and each integer increase is a level. Therefore whatever base your in determines the levels required to advance to the next tier.
However how you classify the breaks, and add the experience, is arbitrary. It is the mathematical property of logarithms themselves to make the size of numbers arbitrary, unlike the leveling problems we discussed before.
A NPC can then calculate the rough benefits of their skill, when searching through all possible options of employment possibly available. They will the, like you proposed have a desire inventory along with regular inventory. From this they can figure out the "price" of their most needed item, in terms of the types of "pay" available, and the "cost" of acquiring the most needed item with their "pay". If they were paid in wheat between several jobs, had no difference in skills, the decision as to which to choose is easy. This will be the starting point, with more elaborate decisions added on after.
if no prior work option
Cycle through available work options -> Calculate potential "pay" -> Predict needed item acquired if "pay" obtained -> remember best option
Also, work options include jobs performed in the past. The algorithm has the ability to check if the job is still available. If so it will continue to work. After each base unit of pay, the NPC AI will decide if it wants to continue again. This will be repeated until a days work is done, which may be calculated by some time of "work exhaustion" or "hunger" for relaxation/socialization/happiness, or that their needs were met. They would then sleep at home. Perhaps this may be the base behavior
Wake up -> Find job -> Do job until "work exhaustion", needs met, etc -> Do errand trading -> Do social (trade memories) -> Sleep
Danger Will Robbinson, exponential curves attempted!
Exponents represent additional dimensionality, or to put it another way another axis. If you feel the need for an exponent, it's because there is a desire to incorporate some other linear dimension that has not been described yet. The result of exponential curves is a wildly fluctuating and very difficult to balance arrangement that almost always degenerates into the developer hacking in kluges to attempt to stabilize it thus invalidating the mathematical model.
It might be good to examine it from the point of view of the player: When will they see level ups occur in their peeps, and can they do anything to influence that process?
Rollback Post to RevisionRollBack
My five-point rating system: Yay, kay, meh, erm, gleh
The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
I understand your concern, and of course if through development I find no reason to use I will forgo. It more comes down to this. A simple linear system is a simplified version of what I propose. I can make it linear by canceling out equations.
Behaviorally exponential equations, and logarithmic equations are different. Albeit one can be other, but not always. When representing physical concepts, one is not always the other.
The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
Yep those definitely are! That is all they are used for officially now.
However there is some iron tools that use iron nuggets in the mod (knife, chisel, and another, cant remember) that will be used for different job types like the butcher and mason, eventually.
The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
I get your point Anglewyrm. And there are two linear dimensions here. Technology/Knowledge is the second dimension, which encompasses a type of knowledge, however is not a "skill" in the sense of increasing a statistic such as speed (first dimension). A piece of knowledge is more like the capability of performing an action.
So yes, planning out what the player will experience, and the order/hierarchy of technologies and skills required to create that game experience, with the corresponding (and next to be created) job types, must be planned out.
This is where your creativity will help tremendously. The structure of gameplay experience is the most important topic, really.
The weird logarithmic method I propose, while including exponential elements, is designed to not fail where previous linear/exponential models have. This model is also not top priority, gameplay is. So if a better idea comes up, or a better idea is compatible, it will of course get nixed.
The simplest form is in relieving the player of tasks that they've done so many times they've lost interest and would rather delegate. If there is a mechanism to delegate tasks to villagers, then they become useful to the player's enjoyment of their Minecrafting time.
Memorable moments and scenes that the player contributed to creating are some of the best experiences a toy/game can provide.
Story lines that provide a sense of development paths at several levels contribute a sense of variety and complexity, an ornamentation of the world.
A basic story archetype is that of raising a family, and the development of a village is an extension of that instinct. So in a way this mod can fulfill an inherent desire of gamers to be fruitful and multiply.
Rollback Post to RevisionRollBack
My five-point rating system: Yay, kay, meh, erm, gleh
This is the notion that the game designer/developer is expressing a world-view of how things work or should work by the rules inherent in their game. This is the artistry of game engineering, the conveyance of opinion not by force but by the player discovering the optimal paths through a world, which are an expression of an opinion of how to best navigate the world.
This can also be construed as morale engineering, that is to say the creation of what is best to do in the game.
Rollback Post to RevisionRollBack
My five-point rating system: Yay, kay, meh, erm, gleh
The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
The whole point of this mod is to delegate! After awhile, as the player you increase your yield per harvest to reduce time harvesting.
As per storylines and character involvement, I have thought about options. This mod is more functional, and in reality could operate and not change gameplay at all, really, besides modifying a few trades.
I have thought about making a second mod, that replaces vanilla villagers, or any modded villagers if the user requests, with "civ" villagers, similar to MCA. As Civ-Now villager expansions will include NBT "memories" of where purchase locations occurred or jobs were performed, there will be social memories. When villagers walk by eachother, they will randomly trade memories and increase social "points".
These modded villagers will have a chat gui to build social points. Also they will have names and be more villager-esque. I also want to make them have 'genetics' where they inherit from their parents. This would be kind of like the sims. There could be a bunch of base skin image files, face image files, color of eyes image files, hair color, etc. A combination of traits could be used to create a skin whenever a new villager was made. Then this skin would be used for that specific villager.
While MCA is wonderful (If I do play minecraft, MCA is a must), it has limitations. The work system is very inefficient, and beyond the guards, villagers don't do much. The marriage/child sytem is nice, but also becomes tedious.
Vanilla - offers a trade system, but currency is so polluted with ideations of loss that it's virtually worthless
MCA - offers the player a spouse and children
Millonaire - I don't play because it was too laggy last time I tried it (a year ago)
Colonies - offers some delegation of work, but charges against the player made it less than desirable
Minions - offers miners for early game mining, but they often disappear/die causing major losses in mined material
Forestry - offers bee and tree genetics, but the necessary equipment is all mid- to late-game costs and the return is rather low.
Social Memories as an Ethic look-up function
If we construe the base atomic binary opinion of "good"/"bad" as an assessment of successful/unsuccessful to the ongoing benefit of an entity, then we can say that ethics are a type of table-of-contents lookup entry into the book of experiences of a society. Swapping memories then becomes a type of registering outcomes of experiences.
If there are environmental factors that can change over long time intervals, then it makes good survival sense to limit the size of memories so that the oldest memories are erased by new incoming memories, and in this way old notions are forgotten/challenged to see if they are still valid.
Rollback Post to RevisionRollBack
My five-point rating system: Yay, kay, meh, erm, gleh
The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
Absolutely. This memory system will be maintained by classifying memories (as best as possible), and counting their appearance through time. Some type of math function would value new memories, and incorporate this calculated "memory retained" value into the respective memory type object. Then, all memories would be subject to "forgetfulness". Memories with value below a threshold will be removed.
At some point only so much memories can be added. Perhaps a villager could accumulate a "ability to memorize" that builds up throughout the day. Every new memory would be assigned a portion of this value when it appears, and it would used to increase the strength of the memory type.
This would help if, say there are many memories added, each would have a weaker effect in the memory bank. Less new memories, would result in them being remembered longer.
Then memories would swap. This could be random, but also influenced on what is "on the memory mind" of the entity. Also, as memories are re-used, leading to benefit, they would be "remembered" increasing their "memory retained" value.
This is kind of like evolution, where weak memories die off, and re-used memories are retained. Then, memories can "infect" new people. Useful memories would spread.
And then yes, each member of society (who socialized with one another) would in general have the same opinion on a topic/outsider/etc. Additionally, if society is very polarized, or sections do not come into contact (rich vs poor), different sub cultures could emerge, influencing revolutions and the stability of society.
Additionally, a "colony" or smaller city founded by a larger, would accumulate a different set of cultural "memories" and eventually drift away from the parent city, unless many people traveled between the two, regulating the differences.
Let's define a situation as a set of choices that lead to a set of outcomes. And an agent as a decision maker that ranks it's preference for the outcomes, and thereby selects a choice within a given situation. For example, a unit on a spatial grid expends energy to travel, acquires more energy as a harvested resource from each location, and has an energy storage capacity. And let's define a simple utility function for the agent to move the unit: Choose an outcome that firstly maximizes stored energy and secondly minimizes movement.
In this illustration, the unit contains 5 of a possible 10 points of energy. Three choices of path are available: Path A costs 2 and pays 5, B costs 4 and pays 10, and C costs 3 and pays 8. Both B and C result in a full ten points of energy for the unit, and C costs less move, so the agent moves the unit to C. If instead the unit had 4/10 points of energy, then B would be the best choice, and if the unit had 7/10 points of energy, then the best choice would be A.
Prediction and Causality
Over the course of several trials, a unit chooses whichever outcome is most suitable at the time, which changes according to circumstance. If we record these responses, we'll get a stochastic curve over the choices that represents the unit's behavior.
For instance, in the above scenario there are a total of eleven possible hunger states, from 0/10 to 10/10. Placing an 'X' next to the best choice for each of the possible states, we find that 'A' is chosen most often, 'B' second, and only seldom is 'C' the best choice.
If given a random unit with an unknown hunger state, we could predict its course of action by rolling percentile dice against the probabilities in the table above. But would assigning a course of action based on these probabilities produce the same approximate total utility score?
In order to proceed with a discussion of artificial morality, it is necessary to define what morality is and what morality is not. Agents within a society act in accordance with their Utility Functions, which rank choices and outcomes for a given agent within a decision space. If the agents have sufficiently diverse properties such as hunger state and hunger drive, then it is possible for the agents to rank outcomes differently, according to each agent's needs.
The result of many agents scoring a given choice will be a stochastic curve around a median choice. The median choice is likely not optimal for any given agent, but the society of agents through individual scoring define a normative behavior when faced with that situation. This normative behavior pattern is the Social Norm for that choice within a given society of agents.
It is therefore possible to measure a given agent's score against the social norm curve, and produce a z-score that expresses distance from the median for the pack. A choice is said to be normal if it is near the center of the spread, and abnormal if the optimal choice for that agent is well away from the center of that spread.
Social Norm is a statistic that is not inherent in the individual, but exists only because a group of agents have faced this choice and scored on it. It is, however, possible to generate something similar to a social norm for an individual who faces the same choice situation multiple times, and therefore may acquire a history of responses. In such case, the individual is comparing their current rating of the outcomes against that agent's history of responses to the situation. It can then be said the best choice for a given agent was normal or abnormal for that agent.
Rollback Post to RevisionRollBack
My five-point rating system: Yay, kay, meh, erm, gleh
The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
I agree with your assessment and have a temporary solution, but a larger economy is required to test the inherent properties you speak of. In essence, your transportation model and making of choices is exactly the problem I have been presented with as well.
A trader as of now, calculates the amount of items (N) per trade route and the distance (X) required to accomplish the trade. For each trade combination available to the trader, the algorithm performs N / X, essentially a "number of item units per meter traveled" value. Then, the highest one of these is selected. The rate of travel time was assumed to be constant, as you can define the entity speed in the navigator object.
This type of logic can be extended, where a set of choices with the top unit in the function (N = marginal benefit) divided and the bottom unit (X = marginal cost) are the same across the entire set of choices. Once the units match up, the choice can be selected.
A variety of methods can be used to "equate" an NPC's value of one food type or quantity, to another. Then the bottom and top units can be converted to make otherwise non-comparable decisions, comparable.
Therefore we are implementing ethics, and all of the above. However, if some artificial of measure of "happiness" or "satisfaction" could be made, then other behaviors would "make sense" to the AI as the "x = (marginal benefit / marginal cost)" is greatest.
I saw a paper by some students at the University of Washington that was about modelling crowd movements, and they had an interesting formula for pathing calculations. Essentially it was a three-story heat map that scored the locations of a grid like so:
One layer was a distance metric
A second layer was time
And the third layer was a measure of undesirability
Movement into squares that were directly in front of another agent had a higher undesirability, as would things like water squares, darkness and proximity to danger. Time could also include a movement cost for entering squares that slow movement, such as soul sand or even substantial elevation changes, ladders etc.
After the total cost for surrounding squares was calculated, then something akin to an A* search was conducted on the grid. As you can probably guess their model is a CPU intensive algorithm, but perhaps some of the concepts are salvagable.
Rollback Post to RevisionRollBack
My five-point rating system: Yay, kay, meh, erm, gleh
The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
Very intersting idea....
I have been thinking of a parallel path calculating algorithm, as a larger city and the corresponding trade routes will use paths and the entities should stick to them. By breaking the world up into different metrics of choice making, and then sharing the information mutually between entities to create a larger dataset, an intricate and more efficient pathing algorithm could be designed. This could facilitate the large distance navigation and entity maneuverability within cities that is needed here.
It kind of falls into crowd sourced datamining, where each individual adds a small piece of knowledge. However, over time these are shared between entities and accumulate. With all the decentralized methodology I used, I've gotten pretty good at spacing out function calls between many entities, using counters, probabilities, and random numbers. Works very well though, you can control within a confident range how often a function will be called, allowing the code to be ran in minecraft.
A thought on optimizing a three-tier heat map with dynamic information in it: Separate out the static/semi-static information in the form of distance, time and some types of aversions. Then have a fourth tier that is exclusively for dynamic/high-update information, such as the other mobile agents.
It could then be possible to do a low-priority background data-collection process by increments for the static data. Some EntityAIMapResearch() type of function that would spend time gathering/updating the heatmap with only several blocks at a pass. Since most civilians will probably hang out in the vicinity of a village, the result is that over time the village will get an updated heatmap.
A good Abstract Data Type for such information could be a sparse vector array.
Rollback Post to RevisionRollBack
My five-point rating system: Yay, kay, meh, erm, gleh
Perhaps you've noticed that zombies perform a type of pursuit that involves registering where the player is, creating a path to that location, and then marching to that destination. In it's most refined form that is called pure pursuit, and is achieved by heading directly for a target, the same mechanism that's used by heat seeking missiles, and it's fairly easy to avoid when the speeds are similar.
There is also lag pursuit, which is what a wolf uses to circle around behind an opponent, which is done by heading towards a place somewhat behind the target along the target's trajectory, a method that quickly places the hunter behind the prey.
And finally there is lead pursuit, also known as an intercept course, which is what tigers use to catch a gazelle and children use to play tag. This type of movement is done by aiming for a point forward of the target along it's trajectory.
Calculating the angles
Let's start with identical speeds for our first iteration of a lead pursuit algorithm. If we examine the target's heading, that is to say what face they are presenting to us, we can directly use that information without any reference to a spatial grid. If we see their 12-o'clock or 6-o'clock then the proper course of action is to head directly at them. But if we see their 3-o'clock or 9-o'clock then the best we can do is run abreast of them until the situation changes.
This covers both extremes of a 90-degree arc, and so all that remains is to determine our heading for the in-between states, which is a simple matter of rotating accordingly. A trig function that provides such a translation is tan2() giving a unit scale 0-1 modifier depending on the angle we see from the target.
And finally, the difference in speed is used as a multiplier on the scale modifier; if we are traveling twice as fast then it becomes possible to make half the angle correction, and so on.
Rollback Post to RevisionRollBack
My five-point rating system: Yay, kay, meh, erm, gleh
The Meaning of Life, the Universe, and Everything.
Join Date:
9/28/2014
Posts:
44
Member Details
I said a couple times I've never thought about something before... And this I have DEFINITELY never thought of or coded. While the intuition makes sense, to incorporate it here I will have to read about these different philosophical forms of "pursuit". This is most interesting and is fundamental in AI.
It is all math, so I understand what you're saying... But I need to spend the time to see it in my head. This type of pathing, with applicable extensions to roads and "city" type pathing, is SUPER important.
Will probably get back to you soonish when I absorb what you have put down. Please put more. Just 6 days and I can start working on this mod again and actually accomplish something...
My model, of course with testing/calibration, will approach over time (at perfect equilibrium), the prices of equivalent exchange 3, reflecting the distribution within the environment and the work required to distribute said resource.
Really, for the user, there is no visible changes other than different trades, that change over time. The trading blocks are essential extensions of villagers or players.
In reality my first series of steps, for the player, we have now touched on nearly everything
1 - A more stable AI system - I need to create a better AI regulation system, that turn's on/off AI's more efficiently and expansively.
2 - Assign "beds" to villagers - Villagers need a home to "live" out of (even if just temporary for mod)
3 - Create chest for inventories associated with villager linked to bed (serve as primary inventory for villager, eventually villagers will have a more robust inventory system)
4 - Create a system where villagers can weight multiple job profitabilities, and select best one.
Then I would like to finalize basic chunk ownership for territory acquisition.
I think that would be most efficient way to begin weaving all these pieces together in a non-arbitrary way
Optimizing the AI loop
The function shouldExecute() within an AI module is the first stop of the Minecraft polling process, and it's purpose is to provide as quick a way to discard further processing of a given AI routine as possible. The linked example is for an AI routine called EntityAIFindShelterFromRain, inspired by the way citizens in The Witcher ran for cover when it was raining.
the shouldExecute() returns true/false telling Minecraft whether to engage the given citizen in further processing.
Beds & Storage
On npc beds, perhaps a recipe that combines a normal bed with a chest and produces a 3x1 model of a bed with an attached footlocker. There could be some indicator of owned vs unassigned beds, perhaps pillow style, or even have two models, one with a pillow and one without.
On owned beds, it would be nice if the player could click to get quick access to that npc's interaction GUI. And on beds that have become unassigned, it could be entertaining to have some historical reference to the last owner, such as "George was killed by Lava."
Creating NPC Beds might even be the method by which the player attracts a new NPC to their village.
Selection of Employment
Need to understand your design for skills before I can make any recommendations. The one on offer is ten generic ranks of skill per npc that slowly shift to that npc's most used skill.
Also, that which the player doesn't experience isn't worth putting too much effort into. An example of that problem is MystCraft, which has an elaborate descriptive language for worlds which gets altered from time to time, but how to use it isn't shared so for all intents and purposes it's wasted effort. The only kind of MystCraft worlds I make are the ones that I can get from random generation plus whatever few tokens I may find throughout the length of my game.
My five-point rating system: Yay, kay, meh, erm, gleh
AI Loop
Yes - Your insights kind of showed me something that was in front of me the whole time. I will still have an AI "managing" module, but this actually makes decisions based on inputs. This may change the AI state inducing changes in other AI should executes.
Beds
Possible crafting recipe, but I think I will skip that for now and save it for later. I have planned on storing the NPC civ id to the chest, as is already done for proto-locked chests. Therefore an NPC would only sleep in a bed where it owned the nearby chest.
This bed system could provide a more elaborate "inn" system to be introduced, which I have considered. Maybe let beds work for you so to speak (in the job table). And yes, I have had that idea allowing NPC beds that remain unclaimed to induce random NPC "traveler" appearances.
Selection of Employment
I realize my ideas are hazy in explanation but at this point, it can be considered analagous to the model you propose. It just however, instead of having a "constant" or "linear" or "exponential" experience increase, it obeys the previously described mathematics. Additionally, it is kind of a two dimensional system. In one, skills determine numeric and therefore quantitative properties of an action an NPC can perform (speed maesurements, bonus amounts, etc). The other is qualititative, where the skill is influence by knowledge and context. For example, a quarry man can mine stone and dirt, but without a more advanced technology, stone and other ores remain unlocked.
The leveling system, after rethinking the explanation, is a logarithmic increase in experience level, or the effect of experience. In reality, its like flint is worth 100xp, copper worth 10^5, bronze 10^8, iron 10^11, etc. They could never be displayed as number as they are too big, However, if you treat them as logarithms the leveling system becomes familiar, however the intricate relationshiop remains intact (tier 2 flint, tier 5 copper, tier 8 bronze, etc). Additionally, the experience would not be cumulative, but also remember the "average experience per action" (or have some type of list), that recalls if the skill was acquired, with say iron (10^11) or bronze (10^8).
So essentially a logarithmic range. Say bronze apprentice ~10^8, journeyman 10^9, master 10^10, or whatever. And in reality, if using base 10, each step is of course ten times the amount of the prior. So when adding exp, it would seem to someone unfamiliar that they were adding way too much experience, but that is of course the value in experience between copper and iron weapons.
You could make each tier is a different type (novice, journeyman, etc), and each integer increase is a level. Therefore whatever base your in determines the levels required to advance to the next tier.
However how you classify the breaks, and add the experience, is arbitrary. It is the mathematical property of logarithms themselves to make the size of numbers arbitrary, unlike the leveling problems we discussed before.
A NPC can then calculate the rough benefits of their skill, when searching through all possible options of employment possibly available. They will the, like you proposed have a desire inventory along with regular inventory. From this they can figure out the "price" of their most needed item, in terms of the types of "pay" available, and the "cost" of acquiring the most needed item with their "pay". If they were paid in wheat between several jobs, had no difference in skills, the decision as to which to choose is easy. This will be the starting point, with more elaborate decisions added on after.
if no prior work option
Cycle through available work options -> Calculate potential "pay" -> Predict needed item acquired if "pay" obtained -> remember best option
Also, work options include jobs performed in the past. The algorithm has the ability to check if the job is still available. If so it will continue to work. After each base unit of pay, the NPC AI will decide if it wants to continue again. This will be repeated until a days work is done, which may be calculated by some time of "work exhaustion" or "hunger" for relaxation/socialization/happiness, or that their needs were met. They would then sleep at home. Perhaps this may be the base behavior
Wake up -> Find job -> Do job until "work exhaustion", needs met, etc -> Do errand trading -> Do social (trade memories) -> Sleep
Danger Will Robbinson, exponential curves attempted!
Exponents represent additional dimensionality, or to put it another way another axis. If you feel the need for an exponent, it's because there is a desire to incorporate some other linear dimension that has not been described yet. The result of exponential curves is a wildly fluctuating and very difficult to balance arrangement that almost always degenerates into the developer hacking in kluges to attempt to stabilize it thus invalidating the mathematical model.
It might be good to examine it from the point of view of the player: When will they see level ups occur in their peeps, and can they do anything to influence that process?
My five-point rating system: Yay, kay, meh, erm, gleh
I understand your concern, and of course if through development I find no reason to use I will forgo. It more comes down to this. A simple linear system is a simplified version of what I propose. I can make it linear by canceling out equations.
Behaviorally exponential equations, and logarithmic equations are different. Albeit one can be other, but not always. When representing physical concepts, one is not always the other.
Yep those definitely are! That is all they are used for officially now.
However there is some iron tools that use iron nuggets in the mod (knife, chisel, and another, cant remember) that will be used for different job types like the butcher and mason, eventually.
I get your point Anglewyrm. And there are two linear dimensions here. Technology/Knowledge is the second dimension, which encompasses a type of knowledge, however is not a "skill" in the sense of increasing a statistic such as speed (first dimension). A piece of knowledge is more like the capability of performing an action.
So yes, planning out what the player will experience, and the order/hierarchy of technologies and skills required to create that game experience, with the corresponding (and next to be created) job types, must be planned out.
This is where your creativity will help tremendously. The structure of gameplay experience is the most important topic, really.
The weird logarithmic method I propose, while including exponential elements, is designed to not fail where previous linear/exponential models have. This model is also not top priority, gameplay is. So if a better idea comes up, or a better idea is compatible, it will of course get nixed.
Engaging and Entertaining the Gamer
A basic story archetype is that of raising a family, and the development of a village is an extension of that instinct. So in a way this mod can fulfill an inherent desire of gamers to be fruitful and multiply.
My five-point rating system: Yay, kay, meh, erm, gleh
Procedural Rhetoric
This is the notion that the game designer/developer is expressing a world-view of how things work or should work by the rules inherent in their game. This is the artistry of game engineering, the conveyance of opinion not by force but by the player discovering the optimal paths through a world, which are an expression of an opinion of how to best navigate the world.
This can also be construed as morale engineering, that is to say the creation of what is best to do in the game.
My five-point rating system: Yay, kay, meh, erm, gleh
The whole point of this mod is to delegate! After awhile, as the player you increase your yield per harvest to reduce time harvesting.
As per storylines and character involvement, I have thought about options. This mod is more functional, and in reality could operate and not change gameplay at all, really, besides modifying a few trades.
I have thought about making a second mod, that replaces vanilla villagers, or any modded villagers if the user requests, with "civ" villagers, similar to MCA. As Civ-Now villager expansions will include NBT "memories" of where purchase locations occurred or jobs were performed, there will be social memories. When villagers walk by eachother, they will randomly trade memories and increase social "points".
These modded villagers will have a chat gui to build social points. Also they will have names and be more villager-esque. I also want to make them have 'genetics' where they inherit from their parents. This would be kind of like the sims. There could be a bunch of base skin image files, face image files, color of eyes image files, hair color, etc. A combination of traits could be used to create a skin whenever a new villager was made. Then this skin would be used for that specific villager.
While MCA is wonderful (If I do play minecraft, MCA is a must), it has limitations. The work system is very inefficient, and beyond the guards, villagers don't do much. The marriage/child sytem is nice, but also becomes tedious.
The Competition
Vanilla - offers a trade system, but currency is so polluted with ideations of loss that it's virtually worthless
MCA - offers the player a spouse and children
Millonaire - I don't play because it was too laggy last time I tried it (a year ago)
Colonies - offers some delegation of work, but charges against the player made it less than desirable
Minions - offers miners for early game mining, but they often disappear/die causing major losses in mined material
Forestry - offers bee and tree genetics, but the necessary equipment is all mid- to late-game costs and the return is rather low.
Social Memories as an Ethic look-up function
If we construe the base atomic binary opinion of "good"/"bad" as an assessment of successful/unsuccessful to the ongoing benefit of an entity, then we can say that ethics are a type of table-of-contents lookup entry into the book of experiences of a society. Swapping memories then becomes a type of registering outcomes of experiences.
If there are environmental factors that can change over long time intervals, then it makes good survival sense to limit the size of memories so that the oldest memories are erased by new incoming memories, and in this way old notions are forgotten/challenged to see if they are still valid.
My five-point rating system: Yay, kay, meh, erm, gleh
Absolutely. This memory system will be maintained by classifying memories (as best as possible), and counting their appearance through time. Some type of math function would value new memories, and incorporate this calculated "memory retained" value into the respective memory type object. Then, all memories would be subject to "forgetfulness". Memories with value below a threshold will be removed.
At some point only so much memories can be added. Perhaps a villager could accumulate a "ability to memorize" that builds up throughout the day. Every new memory would be assigned a portion of this value when it appears, and it would used to increase the strength of the memory type.
This would help if, say there are many memories added, each would have a weaker effect in the memory bank. Less new memories, would result in them being remembered longer.
Then memories would swap. This could be random, but also influenced on what is "on the memory mind" of the entity. Also, as memories are re-used, leading to benefit, they would be "remembered" increasing their "memory retained" value.
This is kind of like evolution, where weak memories die off, and re-used memories are retained. Then, memories can "infect" new people. Useful memories would spread.
And then yes, each member of society (who socialized with one another) would in general have the same opinion on a topic/outsider/etc. Additionally, if society is very polarized, or sections do not come into contact (rich vs poor), different sub cultures could emerge, influencing revolutions and the stability of society.
Additionally, a "colony" or smaller city founded by a larger, would accumulate a different set of cultural "memories" and eventually drift away from the parent city, unless many people traveled between the two, regulating the differences.
Let's define a situation as a set of choices that lead to a set of outcomes. And an agent as a decision maker that ranks it's preference for the outcomes, and thereby selects a choice within a given situation. For example, a unit on a spatial grid expends energy to travel, acquires more energy as a harvested resource from each location, and has an energy storage capacity. And let's define a simple utility function for the agent to move the unit: Choose an outcome that firstly maximizes stored energy and secondly minimizes movement.
In this illustration, the unit contains 5 of a possible 10 points of energy. Three choices of path are available: Path A costs 2 and pays 5, B costs 4 and pays 10, and C costs 3 and pays 8. Both B and C result in a full ten points of energy for the unit, and C costs less move, so the agent moves the unit to C. If instead the unit had 4/10 points of energy, then B would be the best choice, and if the unit had 7/10 points of energy, then the best choice would be A.
Prediction and Causality
Over the course of several trials, a unit chooses whichever outcome is most suitable at the time, which changes according to circumstance. If we record these responses, we'll get a stochastic curve over the choices that represents the unit's behavior.
For instance, in the above scenario there are a total of eleven possible hunger states, from 0/10 to 10/10. Placing an 'X' next to the best choice for each of the possible states, we find that 'A' is chosen most often, 'B' second, and only seldom is 'C' the best choice.
If given a random unit with an unknown hunger state, we could predict its course of action by rolling percentile dice against the probabilities in the table above. But would assigning a course of action based on these probabilities produce the same approximate total utility score?
In order to proceed with a discussion of artificial morality, it is necessary to define what morality is and what morality is not. Agents within a society act in accordance with their Utility Functions, which rank choices and outcomes for a given agent within a decision space. If the agents have sufficiently diverse properties such as hunger state and hunger drive, then it is possible for the agents to rank outcomes differently, according to each agent's needs.
The result of many agents scoring a given choice will be a stochastic curve around a median choice. The median choice is likely not optimal for any given agent, but the society of agents through individual scoring define a normative behavior when faced with that situation. This normative behavior pattern is the Social Norm for that choice within a given society of agents.
It is therefore possible to measure a given agent's score against the social norm curve, and produce a z-score that expresses distance from the median for the pack. A choice is said to be normal if it is near the center of the spread, and abnormal if the optimal choice for that agent is well away from the center of that spread.
Social Norm is a statistic that is not inherent in the individual, but exists only because a group of agents have faced this choice and scored on it. It is, however, possible to generate something similar to a social norm for an individual who faces the same choice situation multiple times, and therefore may acquire a history of responses. In such case, the individual is comparing their current rating of the outcomes against that agent's history of responses to the situation. It can then be said the best choice for a given agent was normal or abnormal for that agent.
My five-point rating system: Yay, kay, meh, erm, gleh
I agree with your assessment and have a temporary solution, but a larger economy is required to test the inherent properties you speak of. In essence, your transportation model and making of choices is exactly the problem I have been presented with as well.
A trader as of now, calculates the amount of items (N) per trade route and the distance (X) required to accomplish the trade. For each trade combination available to the trader, the algorithm performs N / X, essentially a "number of item units per meter traveled" value. Then, the highest one of these is selected. The rate of travel time was assumed to be constant, as you can define the entity speed in the navigator object.
This type of logic can be extended, where a set of choices with the top unit in the function (N = marginal benefit) divided and the bottom unit (X = marginal cost) are the same across the entire set of choices. Once the units match up, the choice can be selected.
A variety of methods can be used to "equate" an NPC's value of one food type or quantity, to another. Then the bottom and top units can be converted to make otherwise non-comparable decisions, comparable.
Therefore we are implementing ethics, and all of the above. However, if some artificial of measure of "happiness" or "satisfaction" could be made, then other behaviors would "make sense" to the AI as the "x = (marginal benefit / marginal cost)" is greatest.
I saw a paper by some students at the University of Washington that was about modelling crowd movements, and they had an interesting formula for pathing calculations. Essentially it was a three-story heat map that scored the locations of a grid like so:
Movement into squares that were directly in front of another agent had a higher undesirability, as would things like water squares, darkness and proximity to danger. Time could also include a movement cost for entering squares that slow movement, such as soul sand or even substantial elevation changes, ladders etc.
After the total cost for surrounding squares was calculated, then something akin to an A* search was conducted on the grid. As you can probably guess their model is a CPU intensive algorithm, but perhaps some of the concepts are salvagable.
My five-point rating system: Yay, kay, meh, erm, gleh
Very intersting idea....
I have been thinking of a parallel path calculating algorithm, as a larger city and the corresponding trade routes will use paths and the entities should stick to them. By breaking the world up into different metrics of choice making, and then sharing the information mutually between entities to create a larger dataset, an intricate and more efficient pathing algorithm could be designed. This could facilitate the large distance navigation and entity maneuverability within cities that is needed here.
It kind of falls into crowd sourced datamining, where each individual adds a small piece of knowledge. However, over time these are shared between entities and accumulate. With all the decentralized methodology I used, I've gotten pretty good at spacing out function calls between many entities, using counters, probabilities, and random numbers. Works very well though, you can control within a confident range how often a function will be called, allowing the code to be ran in minecraft.
A thought on optimizing a three-tier heat map with dynamic information in it: Separate out the static/semi-static information in the form of distance, time and some types of aversions. Then have a fourth tier that is exclusively for dynamic/high-update information, such as the other mobile agents.
It could then be possible to do a low-priority background data-collection process by increments for the static data. Some EntityAIMapResearch() type of function that would spend time gathering/updating the heatmap with only several blocks at a pass. Since most civilians will probably hang out in the vicinity of a village, the result is that over time the village will get an updated heatmap.
A good Abstract Data Type for such information could be a sparse vector array.
My five-point rating system: Yay, kay, meh, erm, gleh
Hunters and Lead Pursuit
Perhaps you've noticed that zombies perform a type of pursuit that involves registering where the player is, creating a path to that location, and then marching to that destination. In it's most refined form that is called pure pursuit, and is achieved by heading directly for a target, the same mechanism that's used by heat seeking missiles, and it's fairly easy to avoid when the speeds are similar.
There is also lag pursuit, which is what a wolf uses to circle around behind an opponent, which is done by heading towards a place somewhat behind the target along the target's trajectory, a method that quickly places the hunter behind the prey.
And finally there is lead pursuit, also known as an intercept course, which is what tigers use to catch a gazelle and children use to play tag. This type of movement is done by aiming for a point forward of the target along it's trajectory.
Calculating the angles
Let's start with identical speeds for our first iteration of a lead pursuit algorithm. If we examine the target's heading, that is to say what face they are presenting to us, we can directly use that information without any reference to a spatial grid. If we see their 12-o'clock or 6-o'clock then the proper course of action is to head directly at them. But if we see their 3-o'clock or 9-o'clock then the best we can do is run abreast of them until the situation changes.
This covers both extremes of a 90-degree arc, and so all that remains is to determine our heading for the in-between states, which is a simple matter of rotating accordingly. A trig function that provides such a translation is tan2() giving a unit scale 0-1 modifier depending on the angle we see from the target.
And finally, the difference in speed is used as a multiplier on the scale modifier; if we are traveling twice as fast then it becomes possible to make half the angle correction, and so on.
My five-point rating system: Yay, kay, meh, erm, gleh
I said a couple times I've never thought about something before... And this I have DEFINITELY never thought of or coded. While the intuition makes sense, to incorporate it here I will have to read about these different philosophical forms of "pursuit". This is most interesting and is fundamental in AI.
It is all math, so I understand what you're saying... But I need to spend the time to see it in my head. This type of pathing, with applicable extensions to roads and "city" type pathing, is SUPER important.
Will probably get back to you soonish when I absorb what you have put down. Please put more. Just 6 days and I can start working on this mod again and actually accomplish something...
A visual to help imagine interaction of facing and placing target in a heading.
My five-point rating system: Yay, kay, meh, erm, gleh