|
You last visited: Today at 19:34
Advertisement
[Error] Prof EXP
Discussion on [Error] Prof EXP within the CO2 Private Server forum part of the Conquer Online 2 category.
06/27/2022, 07:00
|
#1
|
elite*gold: 0
Join Date: Mar 2006
Posts: 599
Received Thanks: 69
|
[Error] Prof EXP
Hello,
Does anyone know what is the error here shown in the picture?
I used this Experience Pts used in client
Code:
private static uint[] ExpPTs = new uint[21] { 0, 1200, 68000, 250000, 640000, 1600000, 4000000, 10000000, 22000000, 40000000, 90000000, 95000000, 142500000, 213750000, 320625000, 480937500, 721406250, 1082109375, 1623164063, 2100000000, 0 };
Yet, still this give me an error.
What could be the reason why I get this exp?
|
|
|
06/27/2022, 13:45
|
#2
|
elite*gold: 100
Join Date: Nov 2020
Posts: 18
Received Thanks: 1
|
WeaponSkillLevelExp.ini < Make sure the values in your source match the ones here.
Once you are sure, you need to add +1 level when it reaches 100 exp. I guess you don't do this checking on source and it just keeps going.
|
|
|
06/27/2022, 14:01
|
#3
|
elite*gold: 0
Join Date: Mar 2006
Posts: 599
Received Thanks: 69
|
Quote:
Originally Posted by ConquerFiles
WeaponSkillLevelExp.ini < Make sure the values in your source match the ones here.
Once you are sure, you need to add +1 level when it reaches 100 exp. I guess you don't do this checking on source and it just keeps going.
|
Thank you for a quick reply, Yes source exp and the client side exp pts (WeaponSkillLevelEXP.ini) is match to what I have it.
Also I added prof.Level++; when the exp reached 100%
Quote:
1,0
2,1200
3,68000
4,250000
5,640000
6,1600000
7,4000000
8,10000000
9,22000000
10,40000000
11,90000000
12,95000000
13,142500000
14,213750000
15,320625000
16,480937500
17,721406250
18,1082109375
19,1623164063
20,2100000000
|
|
|
|
06/27/2022, 15:32
|
#4
|
elite*gold: 100
Join Date: Nov 2020
Posts: 18
Received Thanks: 1
|
prof.Level++; < Can you share your codes about this place, I think you may have a small mistake somewhere.
|
|
|
06/27/2022, 15:44
|
#5
|
elite*gold: 0
Join Date: Mar 2006
Posts: 599
Received Thanks: 69
|
Quote:
Originally Posted by ConquerFiles
prof.Level++; < Can you share your codes about this place, I think you may have a small mistake somewhere.
|
Here is the code for the profiency,
Code:
private static uint[] proficiencyLevelExperience = new uint[21] { 0, 1200, 68000, 250000, 640000, 1600000, 4000000, 10000000, 22000000, 40000000, 90000000, 95000000, 142500000, 213750000, 320625000, 480937500, 721406250, 1082109375, 1623164063, 2100000000, 0 };
public static uint ProficiencyLevelExperience(byte Level)
{
return proficiencyLevelExperience[Math.Min(Level, (byte)20)];
}
public ConcurrentDictionary<uint, Game.MsgServer.MsgProficiency> ClientProf = new ConcurrentDictionary<uint, Game.MsgServer.MsgProficiency>();
private Client.GameClient Owner;
public Proficiency(Client.GameClient _own)
{
Owner = _own;
}
public bool CheckProf(ushort ID, byte level)
{
Game.MsgServer.MsgProficiency prof;
if (ClientProf.TryGetValue(ID, out prof))
{
return prof.Level >= level;
}
return false;
}
public unsafe void Add(ServerSockets.Packet stream, uint ID, uint Level = 0, uint Experience = 0, byte PreviousLevel = 0, bool ClearExp = false)
{
Game.MsgServer.MsgProficiency prof;
if (ClientProf.TryGetValue(ID, out prof))
{
prof.UID = Owner.Player.UID;
prof.Level = Level;
prof.Experience = Experience;
prof.PreviouseLevel = PreviousLevel;
if (prof.Level == 20 || ClearExp)
prof.Experience = 0;
}
else
{
prof = new MsgProficiency();
prof.ID = ID;
prof.UID = Owner.Player.UID;
prof.Level = Level;
prof.Experience = Experience;
if (prof.Level == 20 || ClearExp)
prof.Experience = 0;
prof.PreviouseLevel = PreviousLevel;
ClientProf.TryAdd(prof.ID, prof);
}
Owner.Send(stream.ProficiencyCreate(prof.ID, prof.Level, prof.Experience, Owner.Player.UID));
UpdSpell(prof.ID, prof.Level, prof.Experience, stream);
}
private unsafe void UpdSpell(uint ID, uint level, uint Experience, ServerSockets.Packet stream)
{
Owner.Send(stream.ProficiencyCreate(ID, level, Experience, Owner.Player.UID));
// Owner.Send(stream.UpdateProfExperienceCreate(Experience, Owner.Player.UID, ID));
}
public unsafe void CheckUpdate(uint ID, uint GetExperience, ServerSockets.Packet stream)
{
if (GetExperience == 0)
return;
//if (ID == 1050)
// return;
if (Enum.IsDefined(typeof(Database.MagicType.WeaponsType), (Database.MagicType.WeaponsType)ID))
{
Game.MsgServer.MsgProficiency prof;
if (ClientProf.TryGetValue(ID, out prof))
{
if (prof.Level < 20)
{
//if (Owner.Player.Map == 1039 && GetExperience >= 10000)
// GetExperience /= 40;
//uint nRatio = (uint)(100 - (prof.Level - 12) * 20);//*20
//if (nRatio < 10)
// nRatio = 10;
if (prof.Level < 4)
{
GetExperience *= 100;
}
else if (prof.Level > 13)
{
GetExperience /= (uint)(prof.Level + 30);
}
else
{
GetExperience /= (uint)(prof.Level + 1);
}
//GetExperience = Role.Core.MulDiv(GetExperience, nRatio, 100) / 2;
prof.Experience += GetExperience * Program.ServerConfig.ExpRateProf;
bool leveled = false;
while (prof.Experience >= ProficiencyLevelExperience((byte)prof.Level))
{
prof.Experience -= ProficiencyLevelExperience((byte)prof.Level);
prof.Level++;
if (prof.Level == 20)
{
prof.Experience = 0;
Owner.Send(stream.ProficiencyCreate(prof.ID, prof.Level, prof.Experience, Owner.Player.UID));
Owner.SendSysMesage("You have just leveled your proficiency.", Game.MsgServer.MsgMessage.ChatMode.System);
UpdSpell(prof.ID, prof.Level, prof.Experience, stream);
return;
}
leveled = true;
Owner.SendSysMesage("You have just leveled your proficiency.", Game.MsgServer.MsgMessage.ChatMode.System);
if (prof.PreviouseLevel != 0)
{
if (prof.Level >= prof.PreviouseLevel / 2 && prof.Level < prof.PreviouseLevel)
{
prof.Level = prof.PreviouseLevel;
prof.Experience = 0;
}
}
}
if (leveled)
{
Owner.Send(stream.ProficiencyCreate(prof.ID, prof.Level, prof.Experience, Owner.Player.UID));
}
UpdSpell(prof.ID, prof.Level, prof.Experience, stream);
}
}
else
{
Add(stream, ID);
}
}
}
public unsafe void SendAll(ServerSockets.Packet stream)
{
foreach (var prof in ClientProf.Values)
Owner.Send(stream.ProficiencyCreate(prof.ID, prof.Level, prof.Experience, Owner.Player.UID));
}
|
|
|
06/27/2022, 20:04
|
#6
|
elite*gold: 100
Join Date: Nov 2020
Posts: 18
Received Thanks: 1
|
if (prof.Level >= prof.PreviouseLevel / 2 && prof.Level < prof.PreviouseLevel)
I think your problem comes from here.
For example : After you levelup from 8 to 9 your prof.level = 9 and PreviouseLevel 8
its will not work like this 9 < 8
if you can't, give your discord account, let me check with teamviewer
and why are you returning your prof level to its old level here?
prof.Level = prof.PreviouseLevel;
|
|
|
06/28/2022, 13:58
|
#7
|
elite*gold: 0
Join Date: Mar 2006
Posts: 599
Received Thanks: 69
|
Quote:
Originally Posted by ConquerFiles
if (prof.Level >= prof.PreviouseLevel / 2 && prof.Level < prof.PreviouseLevel)
I think your problem comes from here.
For example : After you levelup from 8 to 9 your prof.level = 9 and PreviouseLevel 8
its will not work like this 9 < 8
if you can't, give your discord account, let me check with teamviewer
and why are you returning your prof level to its old level here?
prof.Level = prof.PreviouseLevel;
|
Thank you for this suggestion,
I found out that the ProfEXP is set to 1,000,000 until prof level 20. It seems like it's on a client side but don't know which should I start.
|
|
|
06/28/2022, 19:33
|
#8
|
elite*gold: 0
Join Date: Jan 2013
Posts: 89
Received Thanks: 27
|
What patch version are you on?
|
|
|
06/28/2022, 21:35
|
#9
|
elite*gold: 0
Join Date: Mar 2006
Posts: 599
Received Thanks: 69
|
Quote:
Originally Posted by thisismyaccountokay
What patch version are you on?
|
Version 5517
|
|
|
06/29/2022, 22:20
|
#10
|
elite*gold: 0
Join Date: Feb 2009
Posts: 262
Received Thanks: 161
|
If I don't wrong, you need to send the packet 1104 when you receive experience.
Code:
public static Packet UpdateProfExperienceCreate(this Packet stream, uint experience, uint uid, uint id)
{
stream.InitWriter();
stream.Write(experience);
stream.Write(uid);
stream.Write(id);
stream.ZeroFill(8);//unknow
stream.Finalize(GamePackets.UpgradeSpellExperience);
return stream;
}
The problem is here:
Code:
while (prof.Experience >= ProficiencyLevelExperience((byte)prof.Level))
Use here a constant like:
Code:
public const uint MaxExperience = 1000000;
while (prof.Experience >= MaxExperience){
prof.Experience -= MaxExperience;
prof.Level++;
if (prof.Level == 20)
{
prof.Experience = 0;
Owner.Send(stream.ProficiencyCreate(prof.ID, prof.Level, prof.Experience, Owner.Player.UID));
Owner.SendSysMesage("You have just leveled your proficiency.", Game.MsgServer.MsgMessage.ChatMode.System);
UpdSpell(prof.ID, prof.Level, prof.Experience, stream);
return;
}
... bla bla bla
}
|
|
|
06/30/2022, 01:14
|
#11
|
elite*gold: 100
Join Date: Nov 2020
Posts: 18
Received Thanks: 1
|
Update packet was wrong. Your method was correct and I added it for him. Its working for him now.
Quote:
Originally Posted by teroareboss1
If I don't wrong, you need to send the packet 1104 when you receive experience.
Code:
public static Packet UpdateProfExperienceCreate(this Packet stream, uint experience, uint uid, uint id)
{
stream.InitWriter();
stream.Write(experience);
stream.Write(uid);
stream.Write(id);
stream.ZeroFill(8);//unknow
stream.Finalize(GamePackets.UpgradeSpellExperience);
return stream;
}
The problem is here:
Code:
while (prof.Experience >= ProficiencyLevelExperience((byte)prof.Level))
Use here a constant like:
Code:
public const uint MaxExperience = 1000000;
while (prof.Experience >= MaxExperience){
prof.Experience -= MaxExperience;
prof.Level++;
if (prof.Level == 20)
{
prof.Experience = 0;
Owner.Send(stream.ProficiencyCreate(prof.ID, prof.Level, prof.Experience, Owner.Player.UID));
Owner.SendSysMesage("You have just leveled your proficiency.", Game.MsgServer.MsgMessage.ChatMode.System);
UpdSpell(prof.ID, prof.Level, prof.Experience, stream);
return;
}
... bla bla bla
}
|
|
|
|
06/30/2022, 14:21
|
#12
|
elite*gold: 0
Join Date: Mar 2006
Posts: 599
Received Thanks: 69
|
Quote:
Originally Posted by teroareboss1
If I don't wrong, you need to send the packet 1104 when you receive experience.
Code:
public static Packet UpdateProfExperienceCreate(this Packet stream, uint experience, uint uid, uint id)
{
stream.InitWriter();
stream.Write(experience);
stream.Write(uid);
stream.Write(id);
stream.ZeroFill(8);//unknow
stream.Finalize(GamePackets.UpgradeSpellExperience);
return stream;
}
The problem is here:
Code:
while (prof.Experience >= ProficiencyLevelExperience((byte)prof.Level))
Use here a constant like:
Code:
public const uint MaxExperience = 1000000;
while (prof.Experience >= MaxExperience){
prof.Experience -= MaxExperience;
prof.Level++;
if (prof.Level == 20)
{
prof.Experience = 0;
Owner.Send(stream.ProficiencyCreate(prof.ID, prof.Level, prof.Experience, Owner.Player.UID));
Owner.SendSysMesage("You have just leveled your proficiency.", Game.MsgServer.MsgMessage.ChatMode.System);
UpdSpell(prof.ID, prof.Level, prof.Experience, stream);
return;
}
... bla bla bla
}
|
Yes, This is correct, This is the code which is already in the source. I am working on a new way to not just set the weapon prof experience to 1000000 exp pts. I want to set the prof experience pts to what in the client side is which is:
I think this is a client side from conquer.exe which @  help me trace the error. which now my problem is where to start which I don't know how to work on exe files.
Code:
1,0
2,1200
3,68000
4,250000
5,640000
6,1600000
7,4000000
8,10000000
9,22000000
10,40000000
11,90000000
12,95000000
13,142500000
14,213750000
15,320625000
16,480937500
17,721406250
18,1082109375
19,1623164063
20,2100000000
|
|
|
06/30/2022, 14:27
|
#13
|
elite*gold: 100
Join Date: Nov 2020
Posts: 18
Received Thanks: 1
|
No no, you don't need to do anything. This problem existed because your update packet was wrong. Already working with those experince rates.
|
|
|
07/01/2022, 17:09
|
#14
|
elite*gold: 0
Join Date: Mar 2006
Posts: 599
Received Thanks: 69
|
Quote:
Originally Posted by ConquerFiles
No no, you don't need to do anything. This problem existed because your update packet was wrong. Already working with those experince rates.
|
Yeah, Thank you for the help. The one we fixed earlier is already in the source at the first place, which is set to Max Experience 1M Exp Pts. I just edit to look like the experience pts from the client but it seems like you said the error is in the Conquer.exe which the weapon exp prof is set to 1,000,000 to all prof level.
|
|
|
07/01/2022, 17:23
|
#15
|
elite*gold: 0
Join Date: Jan 2013
Posts: 89
Received Thanks: 27
|
In 5517 I think they made packet 1104 MsgFlushExp obselete and instead you need to send the required maximum level as part of the MsgWeaponSkill (1025) packet at offset 16.
Double check if you're doing that or feel free to post the snippet of the packet here if you haven't already.
|
|
|
 |
|
Similar Threads
|
Windows 7 Prof. 32Bit auf Windows 7 Prof. 64 Bit
07/11/2013 - Technical Support - 8 Replies
Hey, ich habe die Professional-Version von Windows 7 32 Bit auf meinem Rechner. Da ich aber den Arbeitsspeicher/RAM von 4 Gigabyte auf 8 Gigabyte erweitern will, habe ich mich entschieden mir eine 64 Bit-Version von Windows 7 Professional zu kaufen.
1. Muss ich beim Kauf auf irgendetwas schauen? Ich hätte diese Version gekauft: Windows 7 Professional 64 Bit Deutsch SB Version für wiederaufbereitete PCs: Amazon.de: Software
Wenn es die falsche Version ist, teilt mir das bitte mit.
2. Was...
|
Prof Exp?
08/03/2009 - CO2 Private Server - 0 Replies
I was wondering if anyone knew how to change prof exp or at what pct it levels at in binarys? If you know please tell me =)
|
Weapon prof exp [question]
01/16/2009 - Conquer Online 2 - 11 Replies
Heya peeps,
I was thinking, there is a 'best exp for weapon profiency', since you i.e.: from lvl 7-8 you get .001 pct at pheasants, at lvl 75, and you get .50 pct at hill monsters, at lvl 75. Is there any way of working out what the best
"playerlevel(or maybe potency) - monster level (or potency) relation is?"
If you know it, or have an idea, speak! :D
|
[PSERVER] 5k EXP 5k PROF
12/20/2008 - CO2 Private Server - 4 Replies
delete plz this is not me posting these pointless topic its my bro =.= i changed pass
|
All times are GMT +1. The time now is 19:35.
|
|