I'm not really sure how to describe it, lol. I want to do something with combat details. Taking an example of how it would be in Lua...
Let's say that I have a character. It would be something like chr[n].. chr[0], chr[1] so on. For combat stuff, I want to divide that character's body parts into different parts so it looks like chr[0]["head"], chr[1]["leftArm"].
Now I want to put more info inside that info. Maybe divide the skull into 10 different points and track damage for each.. it'd end up like chr[n]["head"]["skull"][9]["bluntHP"] = 3
This gets pretty tedious to type the more I start nesting it. And to recover the stored data, it'd be x = chr[n][bodyPart][bodyDiv][loc][var], where you have lots of different variables to set, and long functions looking like
ChrStrength = GetChrStrength(armMass, physicalStrength, age, ...)
WpnDamage = CalcWpnDamage(GetWeaponInHand(*chrB), GetWeaponInHandMaterial(*chrB), ...)
GetDamageOnChr(chrA, bodyPart, bodyDiv, loc, chrB, weapon, angle, WpnDamage, ChrStrength, ...).
Actual situation might not be so silly, but this gets long and illegible the more I do it. So, is there some language designed to handle something like this?
Or maybe I'm taking the wrong approach with an typical language. If so, point out what I'm doing wrong