mob/player
Talk(mob/NPC/M)
set src = oview(1)
mob/NPC
Thor
Talk()
..()
if(!usr.LEVEL)//LEVEL holds however many levels the player has earned, or can use in exchange for stat points
usr << "[src] : Come back when you have earned a level"
else
usr.str+=5
usr.LEVEL--
usr.level++ //this hold the players actual level, ex. level == 33 and LEVEL could be 2, when they speak to the NPC their level becomes 35 and their LEVEL = 0
Longbow
//exact same as Thor but gives dex not str
Merlin
//same but with int
There has to be an easier way to implement this, especially with the number of NPCs in a game and the possibility of start combinations (ex usr.dex += 3 usr.str +=2)
You could store your general code in the parent Talk and leave the stat addition to the individual mob types.
Hope this helps.