Всем привет! При компиляции AES: Status info выдает ошибки, как я понял это потому что там используется старый инклуд aes_main вместо aes_v, может кто помочь что изменить надо в исходнике чтобы я смог его скомпилировать или может у кого есть перепиленая версия?
Код:
//AMXXPC compile.exe
// by the AMX Mod X Dev Team
//// aes_status_info.sma
//
// C:\Users\Leivi\Desktop\scripting\aes_status_info.sma(86) : warning 233: symbol "aes_get_player_stats" is marked as deprecated: Use aes_get_player_*() instead.
// C:\Users\Leivi\Desktop\scripting\aes_status_info.sma(97) : warning 233: symbol "aes_get_exp_to_next_level" is marked as deprecated: Use aes_get_level_reqexp() instead.
// Header size: 640 bytes
// Code size: 3544 bytes
// Data size: 1912 bytes
// Stack/heap size: 16384 bytes
// Total requirements: 22480 bytes
//
// 2 Warnings.
// Done.
//
// Compilation Time: 0,23 sec
// ----------------------------------------
Press enter to exit ...
21 Янв 2024
Код:
/*
AES: Status Info v. 0.1
by serfreeman1337 http://gf.hldm.org/
*/
#include <amxmodx>
#include <aes_main>
#define PLUGIN "AES: Status Info"
#define AUTHOR "serfreeman1337"
#define VERSION "0.1"
new statusText
enum _:cvars {
CVAR_FRIEND,
CVAR_ENEMY
}
new cvar[cvars]
new statusFriend[128],statusEnemy[128]
enum _:isTpl {
TPL_EXP,
TPL_EXPNEED,
TPL_LEVEL,
TPL_MAXLEVEL,
TPL_RANK
}
new isTplFormat[isTpl]
new tplForm[][] = {
"<exp>",
"<nxp>",
"<lvl>",
"<mvl>",
"<rnk>"
}
public plugin_init(){
register_plugin(PLUGIN,VERSION,AUTHOR)
statusText = get_user_msgid("StatusText")
register_event("StatusValue", "Show_Status", "bef", "1=2", "2!0")
cvar[CVAR_FRIEND] = register_cvar("aes_status_friend","1 %c1: %p2\n2 %h: %i3%%")
cvar[CVAR_ENEMY] = register_cvar("aes_status_enemy","1 %c1: %p2")
}
public plugin_cfg(){
get_pcvar_string(cvar[CVAR_FRIEND],statusFriend,127)
get_pcvar_string(cvar[CVAR_ENEMY],statusEnemy,127)
for(new i ; i < isTpl ; ++i){
if(contain(statusFriend,tplForm[i]))
isTplFormat[i] |= (1<<0)
if(contain(statusEnemy,tplForm[i]))
isTplFormat[i] |= (1<<1)
}
}
public Show_Status(id){
new targetId = read_data(2)
new isEnemy = get_user_team(id) != get_user_team(targetId)
new statusTxt[128]
copy(statusTxt,127,isEnemy ? statusEnemy : statusFriend)
if(!tplFormat(id,targetId,statusTxt,127,isEnemy))
return
message_begin(MSG_ONE,statusText,.player=id)
write_byte(0)
write_string(statusTxt)
message_end()
}
public tplFormat(id,targetId,statusTxt[],statusLen,isEnemy){
new aStats[AES_ST_END],tmp[32]
if(!aes_get_player_stats(targetId,aStats))
return 0
for(new i ; i < isTpl ; ++i){
if(isTplFormat[i] & (1<<isEnemy)){
switch(i){
case TPL_EXP:{
formatex(tmp,31,"%d",aStats[AES_ST_EXP])
replace_all(statusTxt,statusLen,tplForm[i],tmp)
}
case TPL_EXPNEED:{
formatex(tmp,31,"%d",aes_get_exp_to_next_level(aStats[AES_ST_LEVEL]))
replace_all(statusTxt,statusLen,tplForm[i],tmp)
}
case TPL_LEVEL:{
formatex(tmp,31,"%d",aStats[AES_ST_LEVEL])
replace_all(statusTxt,statusLen,tplForm[i],tmp)
}
case TPL_MAXLEVEL:{
formatex(tmp,31,"%d",aes_get_max_level())
replace_all(statusTxt,statusLen,tplForm[i],tmp)
}
case TPL_RANK:{
aes_get_level_name(aStats[AES_ST_LEVEL],tmp,31,id)
replace_all(statusTxt,statusLen,tplForm[i],tmp)
}
}
}
}
replace_all(statusTxt,statusLen,"\n","^n")
return 1
}