summaryrefslogtreecommitdiff
path: root/src/map/chrif.cpp
diff options
context:
space:
mode:
authorBen Longbons <b.r.longbons@gmail.com>2013-01-15 15:27:59 -0800
committerBen Longbons <b.r.longbons@gmail.com>2013-01-17 17:35:36 -0800
commitb34acd1a97e7f087882675e812fda04d303dc6e0 (patch)
tree59a3f0779027a5020fff04661ce0373feb623361 /src/map/chrif.cpp
parentf909528c7e64ac7180d9a544f12912efd0867a67 (diff)
downloadtmwa-b34acd1a97e7f087882675e812fda04d303dc6e0.tar.gz
tmwa-b34acd1a97e7f087882675e812fda04d303dc6e0.tar.bz2
tmwa-b34acd1a97e7f087882675e812fda04d303dc6e0.tar.xz
tmwa-b34acd1a97e7f087882675e812fda04d303dc6e0.zip
Remove PC/mob disguises and hard-coded classes
Diffstat (limited to 'src/map/chrif.cpp')
-rw-r--r--src/map/chrif.cpp28
1 files changed, 1 insertions, 27 deletions
diff --git a/src/map/chrif.cpp b/src/map/chrif.cpp
index ee8113a..ef4c160 100644
--- a/src/map/chrif.cpp
+++ b/src/map/chrif.cpp
@@ -640,7 +640,6 @@ int chrif_changedsex(int fd)
{
int acc, sex, i;
struct map_session_data *sd;
- struct pc_base_job s_class;
acc = RFIFOL(fd, 2);
sex = RFIFOL(fd, 6);
@@ -651,17 +650,7 @@ int chrif_changedsex(int fd)
{
if (sd != NULL && sd->status.sex != sex)
{
- s_class = pc_calc_base_job(sd->status.pc_class);
- if (sd->status.sex == 0)
- {
- sd->status.sex = 1;
- sd->sex = 1;
- }
- else if (sd->status.sex == 1)
- {
- sd->status.sex = 0;
- sd->sex = 0;
- }
+ sd->sex = sd->status.sex = !sd->status.sex;
// to avoid any problem with equipment and invalid sex, equipment is unequiped.
for (i = 0; i < MAX_INVENTORY; i++)
{
@@ -669,21 +658,6 @@ int chrif_changedsex(int fd)
&& bool(sd->status.inventory[i].equip))
pc_unequipitem(sd, i, CalcStatus::NOW);
}
- // reset skill of some job
- if (s_class.job == 19 || s_class.job == 4020
- || s_class.job == 4042 || s_class.job == 20
- || s_class.job == 4021 || s_class.job == 4043)
- {
-
- clif_updatestatus(sd, SP_SKILLPOINT);
- // change job if necessary
- if (s_class.job == 20 || s_class.job == 4021
- || s_class.job == 4043)
- sd->status.pc_class -= 1;
- else if (s_class.job == 19 || s_class.job == 4020
- || s_class.job == 4042)
- sd->status.pc_class += 1;
- }
// save character
chrif_save(sd);
sd->login_id1++; // change identify, because if player come back in char within the 5 seconds, he can change its characters