world/mob = /mob/Player
var
preset_stat = list(
"Homo Sapiens Sapiens" = list(
"height" = 175,
"stamina" = list("max" = 100, "max exp" = 1000),
"upper body" = list(
"strength" = list("max" = 10, "max exp" = 100))
"lower body" = list(
"strength" = list("max" = 10, "max exp" = 100),
"endurance" = list("max" = 10, "max exp" = 100))))
mob/Login()
set_stats(preset_stat["Homo Sapiens Sapiens"])
or
mob/Login()
switch(input("Select race/species", "Race/Species") in list("Homo Sapiens Sapiens", "Homo Sapiens Idaltu", "Homo Neanderthalis"))
if ("Homo Sapiens Sapiens")
var/mob/HSS/H = new
H.key = src.key
if ("Homo Sapiens Idaltu")
else if ("Homo Neanderthalis")
mob
HSS
height = 175
stamina = list("max" = 100, "max exp" = 1000),
upper body = list(
"strength" = list("max" = 10, "max exp" = 100))
lower body = list(
"strength" = list("max" = 10, "max exp" = 100),
"endurance" = list("max" = 10, "max exp" = 100))
Problem description:
Which one is more efficient?
Is it better to turn a player mob into a HSS mob, or have the existing mob take in stats from a list?
As you can see, the plan is to have options for different races or species.
Alternative methods would be greatly appreciated (still a beginner on this language).
Thanks