PcCafe packet improvements.

Contributed by darkillust.
This commit is contained in:
MobiusDev 2019-01-08 00:24:18 +00:00
parent b82e5a66a3
commit 37c751fbd1
30 changed files with 40 additions and 40 deletions

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -329,7 +329,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -357,7 +357,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -357,7 +357,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -357,7 +357,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -357,7 +357,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -357,7 +357,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -357,7 +357,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -357,7 +357,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -357,7 +357,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}

View File

@ -123,7 +123,7 @@ public final class AdminPcCafePoints implements IAdminCommandHandler
target.setPcCafePoints(pcCafeCount);
target.sendMessage("Admin decreased your PC Cafe point(s) by " + value + "!");
BuilderUtil.sendSysMessage(activeChar, "You decreased PC Cafe point(s) of " + target.getName() + " by " + value);
target.sendPacket(new ExPCCafePointInfo(pcCafeCount, value, 1));
target.sendPacket(new ExPCCafePointInfo(target.getPcCafePoints(), -value, 1));
break;
}
case "rewardOnline":

View File

@ -357,7 +357,7 @@ public class MultiSellChoose implements IClientIncomingPacket
case PC_CAFE_POINTS:
{
player.setPcCafePoints((int) (player.getPcCafePoints() - totalCount));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) totalCount, 1));
player.sendPacket(new ExPCCafePointInfo(player.getPcCafePoints(), (int) -totalCount, 1));
break;
}
default:

View File

@ -47,8 +47,8 @@ public class ExPCCafePointInfo implements IClientOutgoingPacket
_points = points;
_mAddPoint = pointsToAdd;
_mPeriodType = 1;
_remainTime = 42; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 3 : 0; // When using points is 3
_remainTime = 0; // No idea why but retail sends 42..
_pointType = pointsToAdd < 0 ? 2 : 1; // When using points is 3
_time = time;
}