Ovnyx
Member
- Joined
- Jul 25, 2017
- Messages
- 163
- Solutions
- 2
- Reaction score
- 7
setVarStats not setVarStatsPercent.Boosts name changes and 2 new functions (#2485) · otland/forgottenserver@c7bef15 (https://github.com/otland/forgottenserver/commit/c7bef1519a5040eb82d4923005602b0e026f7d96#diff-66217ab5c054d1ce40c5940ec02eb541)hi, i was modifying tfs 1.3 the last one TFS 1.3, i got some errors while compiling, i fix most of them but i cant figure out this ones:
View attachment 38663
where are this identifiers declared? i look at the enums and they are there, and i did all the change in order acording to THIS
thanks in advice!![]()
1>------ Build started: Project: theforgottenserver, Configuration: Release x64 ------
1>tools.cpp
1>c:\users\legion\desktop\forgottenserver-master\src\tools.cpp(1029): error C2065: 'SPECIALSKILL_HITPOINTSLEECHCHANCE': undeclared identifier
1>c:\users\legion\desktop\forgottenserver-master\src\tools.cpp(1031): error C2065: 'SPECIALSKILL_HITPOINTSLEECHAMOUNT': undeclared identifier
1>c:\users\legion\desktop\forgottenserver-master\src\tools.cpp(1033): error C2065: 'SPECIALSKILL_MANAPOINTSLEECHCHANCE': undeclared identifier
1>c:\users\legion\desktop\forgottenserver-master\src\tools.cpp(1035): error C2065: 'SPECIALSKILL_MANAPOINTSLEECHAMOUNT': undeclared identifier
1>c:\users\legion\desktop\forgottenserver-master\src\tools.cpp(1029): error C2051: case expression not constant
1>c:\users\legion\desktop\forgottenserver-master\src\tools.cpp(1031): error C2051: case expression not constant
1>c:\users\legion\desktop\forgottenserver-master\src\tools.cpp(1033): error C2051: case expression not constant
1>c:\users\legion\desktop\forgottenserver-master\src\tools.cpp(1035): error C2051: case expression not constant
1>Done building project "theforgottenserver.vcxproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
itemAbilityTypes specialSkillToAbility(uint8_t skillid)
{
switch (skillid) {
case SPECIALSKILL_CRITICALHITCHANCE:
return ITEM_ABILITY_CRITICALHITCHANCE;
case SPECIALSKILL_CRITICALHITAMOUNT:
return ITEM_ABILITY_CRITICALHITAMOUNT;
case SPECIALSKILL_HITPOINTSLEECHCHANCE:
return ITEM_ABILITY_LIFELEECHCHANCE;
case SPECIALSKILL_HITPOINTSLEECHAMOUNT:
return ITEM_ABILITY_LIFELEECHAMOUNT;
case SPECIALSKILL_MANAPOINTSLEECHCHANCE:
return ITEM_ABILITY_MANALEECHCHANCE;
case SPECIALSKILL_MANAPOINTSLEECHAMOUNT:
return ITEM_ABILITY_MANALEECHAMOUNT;
default:
return ITEM_ABILITY_NONE;
}
}
itemAbilityTypes specialSkillToAbility(uint8_t skillid)
{
switch (skillid) {
case SPECIALSKILL_CRITICALHITCHANCE:
return ITEM_ABILITY_CRITICALHITCHANCE;
case SPECIALSKILL_CRITICALHITAMOUNT:
return ITEM_ABILITY_CRITICALHITAMOUNT;
case SPECIALSKILL_LIFELEECHCHANCE:
return ITEM_ABILITY_LIFELEECHCHANCE;
case ITEM_ABILITY_LIFELEECHAMOUNT:
return ITEM_ABILITY_LIFELEECHAMOUNT;
case ITEM_ABILITY_MANALEECHCHANCE:
return ITEM_ABILITY_MANALEECHCHANCE;
case ITEM_ABILITY_MANALEECHAMOUNT:
return ITEM_ABILITY_MANALEECHAMOUNT;
default:
return ITEM_ABILITY_NONE;
}
}
1>------ Build started: Project: theforgottenserver, Configuration: Release x64 ------
1>tools.cpp
1>condition.obj : error LNK2001: unresolved external symbol "public: void __cdecl Player::setVarStats(enum stats_t,int)" (?setVarStats@Player@@QEAAXW4stats_t@@H@Z)
1>C:\Users\LEGION\Desktop\forgottenserver-master\vc14\x64\Release\theforgottenserver-x64.exe : fatal error LNK1120: 1 unresolved externals
1>Done building project "theforgottenserver.vcxproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

1>------ Build started: Project: theforgottenserver, Configuration: Release x64 ------
1>tools.cpp
1>condition.obj : error LNK2001: unresolved external symbol "public: void __cdecl Player::setVarStats(enum stats_t,int)" (?setVarStats@Player@@QEAAXW4stats_t@@H@Z)
1>C:\Users\LEGION\Desktop\forgottenserver-master\vc14\x64\Release\theforgottenserver-x64.exe : fatal error LNK1120: 1 unresolved externals
1>Done building project "theforgottenserver.vcxproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
ye i was just editingthe post D; i taked from the repo and put it on my player.cpp and it finally compile succeeded, going to test it thank you very muchNo,setVarStatsnotsetVarStatsPercent.
1>combat.obj : error LNK2001: unresolved external symbol "public: __int64 __cdecl Player::getEffectiveAbility(enum itemAbilityTypes)const " (?getEffectiveAbility@Player@@QEBA_JW4itemAbilityTypes@@@Z)
int64_t Player::getEffectiveAbility(itemAbilityTypes abilityType) const
'C:\Windows\SysWOW64\WindowsPowerShell\v1.0\x64\Release\vcpkg.applocal.log'.
1>En C:\Users\LEGION\Desktop\vcpkg\scripts\buildsystems\msbuild\applocal.ps1: 12 Carácter: 5
1>+ Set-Content -Path $copiedFilesLog -Value "" -Encoding UTF8
1>+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1> + CategoryInfo : ObjectNotFound: (C:\Windows\SysW...kg.applocal.log:String) [Set-Content], DirectoryNotFo
1> undException
1> + FullyQualifiedErrorId : GetContentWriterDirectoryNotFoundError,Microsoft.PowerShell.Commands.SetContentCommand
1>