Posted By: LewyT
more skills - 11/09/11 02:47
Hello and greetings from a new forum member.
I am new to gamestudio and lite-c.
I have read and played with the tutorial workshops and modified one to start building my own game
It appears I will need more "skills" for my player entities than what is available.
After searching the help file I found "atypes.h" and modified the line that reads "skill[100];" to "skill[200];"
That didn't cause any errors so I wrote a few defines in my game file:
That didn't cause any errors so I used one in my entity action :
that didn't cause any errors either but when I display the info in a panel it shows the value is zero (0) when it should be 100
What am I missing here?
Can I simply not use skills over 100?
please note these code snippets are not my exact code but abbreviated form
I am new to gamestudio and lite-c.
I have read and played with the tutorial workshops and modified one to start building my own game
It appears I will need more "skills" for my player entities than what is available.
After searching the help file I found "atypes.h" and modified the line that reads "skill[100];" to "skill[200];"
That didn't cause any errors so I wrote a few defines in my game file:
Code:
// STATS #define LIFE skill[101] #define STRENGTH skill[102] #define AGILITY skill[103] #define MIND skill[104] #define SPIRIT skill[105] // VITALS #define HEALTH skill[106] #define MAXHEALTH skill[107] #define HEALING skill[108] #define WOUNDS skill[109] #define STAMINA skill[110] #define MAXSTAMINA skill[111] #define STAMREGEN skill[112] #define MANA skill[113] #define MAXMANA skill[114] #define MANAREGEN skill[115]
That didn't cause any errors so I used one in my entity action :
Code:
var ph; action updatecharacter() // this is called when the entity is created { // initialize stuff my.HEALTH = 100; while (1) // action loop { ph = my.HEALTH // all the character movement and action handling in here wait(1); } }
that didn't cause any errors either but when I display the info in a panel it shows the value is zero (0) when it should be 100
Code:
PANEL* panDisplay = { digits(5, 20, "health = %0.f", *, 1, ph); flags = SHOW; }
What am I missing here?
Can I simply not use skills over 100?
please note these code snippets are not my exact code but abbreviated form