Jump to content
  • 0

Changing Character Max Stats Parameter


Question

Posted

Alright, so yeah.. How to add new parameters for 2nd job max stats?

I know there's already a set parameter for 1st class&secondjob and for third class separately..

For 1st class to 2nd class (till trans): the maximum stats can be set through here..


// Max limit of char stats. (agi, str, etc.)
max_parameter: 99

and for third class. its here..


// Same as max_parameter, but for 3rd classes.
max_third_parameter: 120

Now what I want is that to separate the maximum stats for 1st class (till knight and other jobs) from trans (2nd job)..

How can I do it?

I have a snippet but don't know which way to go after this.. Hope someone can help me.. Thanks!

So basically I started here at battle.c

{ "max_parameter",                      &battle_config.max_parameter,                   99,     10,     10000,          }, -- for 1st job
{ "max_second_parameter",                &battle_config.max_second_parameter,             120,    10,     10000,          }, -- 2nd job
{ "max_third_parameter",                &battle_config.max_third_parameter,             120,    10,     10000,          }, -- 3nd job

and then went to battle.h

int max_third_parameter; - for 3rd job
int max_parameter; - 1st job
int max_second_parameter; - 2nd job

I'm stuck till here. Don't know where to put next.. should I go to status.c?

Why i'm doing this? Cause i'm currently using pre-renewal mode. Hope someone could help me. Thanks in advance!

22 answers to this question

Recommended Posts

Posted

mainly what you want to look for then is this, and define which jobs you want

#define pc_maxparameter(sd) ( ((((sd)->class_&MAPID_UPPERMASK) == MAPID_KAGEROUOBORO) || (sd)->class_&JOBL_THIRD ? ((sd)->class_&JOBL_BABY ? battle_config.max_baby_third_paramater : battle_config.max_third_parameter) : ((sd)->class_&JOBL_BABY ? battle_config.max_baby_parameter : battle_config.max_parameter)) )

in pc.h

Posted (edited)

mainly what you want to look for then is this, and define which jobs you want

#define pc_maxparameter(sd) ( ((((sd)->class_&MAPID_UPPERMASK) == MAPID_KAGEROUOBORO) || (sd)->class_&JOBL_THIRD ? ((sd)->class_&JOBL_BABY ? battle_config.max_baby_third_paramater : battle_config.max_third_parameter) : ((sd)->class_&JOBL_BABY ? battle_config.max_baby_parameter : battle_config.max_parameter)) )

in pc.h

This is what I dont' understand. Can you help me what to do with pc.h? Cause whenever I include jobl_2 lots of errors occurs when recompiling. Thanks!

#define pc_maxparameter(sd)   ( ((((sd)->class_&MAPID_UPPERMASK) == MAPID_KAGEROUOBORO) || (sd)->class_&JOBL_THIRD ? ((sd)->class_&JOBL_BABY ? battle_config.max_baby_third_paramater : battle_config.max_third_parameter) : ((sd)->class_&JOBL_BABY ? battle_config.max_baby_parameter : battle_config.max_parameter) : ((sd)->class_&JOBL_2 ? battle_config.max_second_parameter : battle_config.max_second_parameter)) )

Using the code above. I got tons of error.

Edited by emong
Posted

yep i can, if anyone gets it before me then please do so =)

just first classes for now or ?

For all classes.. :) 1st class, 2nd class and 3rd class /w kagerou.. I really don't understand the statement in pc.h

Posted

here's an example that works well. Anyone can add on to this if you like

current code modifies novice only to look at 3rd stats

#define pc_maxparameter(sd)   ( (((    (sd)->class_&MAPID_UPPERMASK) == MAPID_KAGEROUOBORO) || (sd)->class_&JOBL_THIRD ? ((sd)->class_&JOBL_BABY ? battle_config.max_baby_third_paramater : battle_config.max_third_parameter)  [color=#ff0000]: (sd->class_&MAPID_UPPERMASK) == MAPID_NOVICE ? (battle_config.max_third_parameter)[/color] : ((sd)->class_&JOBL_BABY ? battle_config.max_baby_parameter : battle_config.max_parameter)) )

Posted (edited)

here's an example that works well. Anyone can add on to this if you like

current code modifies novice only to look at 3rd stats

#define pc_maxparameter(sd)   ( (((	(sd)->class_&MAPID_UPPERMASK) == MAPID_KAGEROUOBORO) || (sd)->class_&JOBL_THIRD ? ((sd)->class_&JOBL_BABY ? battle_config.max_baby_third_paramater : battle_config.max_third_parameter)  [color=#ff0000]: (sd->class_&MAPID_UPPERMASK) == MAPID_NOVICE ? (battle_config.max_third_parameter)[/color] : ((sd)->class_&JOBL_BABY ? battle_config.max_baby_parameter : battle_config.max_parameter)) )

I still don't get this ... how will it affect the trans stats?

I copied the codes and put it onto pc.h and receive some errors..

here's the error..


1>d:\svn\r-athena\src\map\atcommand.c(2633) : error C2039: 'max_baby_third_paramater' : is not a member of 'Battle_Config'
1>        d:\svn\r-athena\src\map\battle.h(106) : see declaration of 'Battle_Config'
1>d:\svn\r-athena\src\map\atcommand.c(2633) : fatal error C1903: unable to recover from previous error(s); stopping compilation
1>d:\svn\r-athena\src\map\pc.c(5834) : error C2039: 'max_baby_third_paramater' : is not a member of 'Battle_Config'

Edited by emong
Posted

i wouldn't know of an efficient way of this, but i would copy the same line for each job, where i put mapid novice, it would be mapid swordy, and so on...

YOu could probably do it by JOBL_ , to see if that may make it easier, but there may be someone else that can make this process a bit easier.

Posted

i wouldn't know of an efficient way of this, but i would copy the same line for each job, where i put mapid novice, it would be mapid swordy, and so on...

YOu could probably do it by JOBL_ , to see if that may make it easier, but there may be someone else that can make this process a bit easier.

I also tried changing the map_id=swordie to other still having error with the code you have provided... it roots down to other errors.

Posted

you're using rathena right,

'max_baby_third_paramater should be defined already in rathena

if I wanted it to be a swordman instead that uses 3rd job stats, then it would be

MAPID_SWORDMAN

Posted

you're using rathena right,

'max_baby_third_paramater should be defined already in rathena

if I wanted it to be a swordman instead that uses 3rd job stats, then it would be

MAPID_SWORDMAN

Okay.. Somehow I get it. What is the summary of codes for trans job for that map_id? map_id=uppermask? = 2-1 and 2-2 class?

Posted

is this also same to the question "how to change all the stats and change it to 500?" in pre- mode not in renewal.

No it isn't. You can directly change your stats to 500 via player.conf >> parameter..

This issue/topic support is all about adding new parameters for 2nd job.. :) Do you have any idea how to implement this?

Posted

oh ok. i have a problem. my max stats is 500 and max lvl is 999 but when i got 999 not all my stats are 500 help please.

Create another topic cause mine isn't solved yet.

Posted

#define pc_maxparameter(sd)   ( ((((sd)->class_&MAPID_UPPERMASK) == MAPID_KAGEROUOBORO) || (sd)->class_&JOBL_THIRD ? ((sd)->class_&JOBL_BABY ? battle_config.max_baby_third_parameter : battle_config.max_third_parameter) : ((sd)->class_&JOBL_BABY ? battle_config.max_baby_parameter : ( (sd)->class_&JOBL_2 ? 60 : battle_config.max_parameter)) ) )

see that

(sd)->class_&JOBL_2 ? 60

change that to your desire value

lazy to make it configurable in conf\battle

Posted

#define pc_maxparameter(sd)   ( ((((sd)->class_&MAPID_UPPERMASK) == MAPID_KAGEROUOBORO) || (sd)->class_&JOBL_THIRD ? ((sd)->class_&JOBL_BABY ? battle_config.max_baby_third_parameter : battle_config.max_third_parameter) : ((sd)->class_&JOBL_BABY ? battle_config.max_baby_parameter : ( (sd)->class_&JOBL_2 ? 60 : battle_config.max_parameter)) ) )

see that

(sd)->class_&JOBL_2 ? 60

change that to your desire value

lazy to make it configurable in conf\battle

Amazing! It worked! But didn't fully understand the JOBL_2 I thought it was exclusive for transcendent job.. Upon checking it. JOBL_2 includes wizard and monks...

By chance, do you know the code for all transcendent job only? TY!

Posted

map.h

#define JOBL_2_1 0x100 //256
#define JOBL_2_2 0x200 //512
#define JOBL_2 0x300

#define JOBL_UPPER 0x1000 //4096
#define JOBL_BABY 0x2000  //8192
#define JOBL_THIRD 0x4000 //16384

//First Jobs
//Note the oddity of the novice:
//Super Novices are considered the 2-1 version of the novice! Novices are considered a first class type, too...
enum {
//Novice And 1-1 Jobs
MAPID_NOVICE = 0x0,
MAPID_SWORDMAN,
MAPID_MAGE,
MAPID_ARCHER,
MAPID_ACOLYTE,
MAPID_MERCHANT,
.........

.... feel lazy to explain

anyway you look at the file you might figure out yourself

MAPID_NOVICE = 0x0,

MAPID_SWORDMAN, // <-- 0x1

...

MAPID_CRUSADER = JOBL_2_2|0x1,

MAPID_SAGE, // <-- 0x202

...

MAPID_ROYAL_GUARD = JOBL_THIRD|JOBL_2_2|0x1,

MAPID_SORCERER,// <-- 0x4202

...

they are in hex value

Posted

map.h

#define JOBL_2_1 0x100 //256
#define JOBL_2_2 0x200 //512
#define JOBL_2 0x300

#define JOBL_UPPER 0x1000 //4096
#define JOBL_BABY 0x2000  //8192
#define JOBL_THIRD 0x4000 //16384

//First Jobs
//Note the oddity of the novice:
//Super Novices are considered the 2-1 version of the novice! Novices are considered a first class type, too...
enum {
//Novice And 1-1 Jobs
MAPID_NOVICE = 0x0,
MAPID_SWORDMAN,
MAPID_MAGE,
MAPID_ARCHER,
MAPID_ACOLYTE,
MAPID_MERCHANT,
.........

.... feel lazy to explain

anyway you look at the file you might figure out yourself

MAPID_NOVICE = 0x0,

MAPID_SWORDMAN, // <-- 0x1

...

MAPID_CRUSADER = JOBL_2_2|0x1,

MAPID_SAGE, // <-- 0x202

...

MAPID_ROYAL_GUARD = JOBL_THIRD|JOBL_2_2|0x1,

MAPID_SORCERER,// <-- 0x4202

...

they are in hex value

so basically if I put this...


MAPID_SAGE,
MAPID_BARDDANCER,
MAPID_MONK,
MAPID_ALCHEMIST,
MAPID_ROGUE,

to here..


MAPID_SUPER_NOVICE = JOBL_2_1|0x0,
MAPID_KNIGHT,
MAPID_WIZARD,
MAPID_HUNTER,
MAPID_PRIEST,
MAPID_BLACKSMITH,
MAPID_ASSASSIN,
MAPID_STAR_GLADIATOR,
---->

MAPID_SAGE,
MAPID_BARDDANCER,
MAPID_MONK,
MAPID_ALCHEMIST,
MAPID_ROGUE,
<-----
MAPID_KAGEROUOBORO = JOBL_2_1|0x0A,
MAPID_DEATH_KNIGHT = JOBL_2_1|0x0D,

will fix everything? or no because of the hexstrings?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...