Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Save Skills */
- for (i = 1; i <= SK_ARRAY_MAX; i++) {
- if (GET_SKILL(ch, i))
- fprintf(fl, "Skil: %d %d %d %d\n", i, GET_SKILL(ch, i), GET_SKILL_RANK(ch, i), GET_SKILL_XP(ch, i));
- }
- /**************************************/
- static void load_skills(FILE *fl, struct char_data *ch) {
- int num = 0, num2 = 0;
- char line[MAX_INPUT_LENGTH + 1];
- do {
- get_line(fl, line);
- sscanf(line, "%d %d %d %d", &num, &num2, &num3, &num4);
- if (num != 0) {
- GET_SKILL(ch, num) = num2;
- GET_SKILL_RANK(ch, num) = num3;
- GET_SKILL_XP(ch, num) = num4;
- }
- } while (num != 0);
- }
Advertisement
Add Comment
Please, Sign In to add comment