17.01.2014, 01:45
(
Последний раз редактировалось [TC]XxJuggaloxX; 18.01.2014 в 02:28.
Причина: Fixed a few errors on my part.
)
*EDIT* This has been updated to fix some errors that have been found by some people. This should be working now! Enjoy! - 1/17/2014
If you are having this error
Download: REMOVED
-This is for those of you lazy people.
For the record, this literally took me 2 minutes to figure out how to fix this, hopefully this download will help you as they are mine, They arnt edited other than from what you see below, They work for me, so they should work for you.
This is what you need to do.
Navigate to:
\pawno\include\YSI\y_als
Open:
impl.inc
Find:
Change to:
Find:
Change to:
Save and Close the file.
Now thats done. You need to edit one more file.
Navigate to:
\pawno\include\YSI\y_hooks
Open:
impl.inc
Find:
Change to:
Find:
Change to:
Find:
Change to:
Find:
Change to:
Find:
Change to:
Find:
Change to:
Save and Close the file.
Now go compile and have fun!
If you are having this error
Код:
error 025: function heading differs from prototype
-This is for those of you lazy people.
For the record, this literally took me 2 minutes to figure out how to fix this, hopefully this download will help you as they are mine, They arnt edited other than from what you see below, They work for me, so they should work for you.
This is what you need to do.
Navigate to:
\pawno\include\YSI\y_als
Open:
impl.inc
Find:
pawn Код:
#define ALS_DO_PlayerTakeDamage<%0> %0<PlayerTakeDamage,iifi>(more:playerid,more:issuerid,Float:amount,end:weaponid)
pawn Код:
#define ALS_DO_PlayerTakeDamage<%0> %0<PlayerTakeDamage,iifii>(more:playerid,more:issuerid,Float:amount,more:weaponid,end:bodypart)
pawn Код:
#define ALS_DO_PlayerGiveDamage<%0> %0<PlayerGiveDamage,iifi>(more:playerid,more:damagedid,Float:amount,end:weaponid)
pawn Код:
#define ALS_DO_PlayerGiveDamage<%0> %0<PlayerGiveDamage,iifii>(more:playerid,more:damagedid,Float:amount,more:weaponid,end:bodypart)
Now thats done. You need to edit one more file.
Navigate to:
\pawno\include\YSI\y_hooks
Open:
impl.inc
Find:
pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid)
pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid, bodypart)
pawn Код:
P:2("Hooks_OnPlayerTakeDamage called: %d, %d, %f, %d", playerid, issuerid, Float:amount, weaponid);
pawn Код:
P:2("Hooks_OnPlayerTakeDamage called: %d, %d, %f, %d, %d", playerid, issuerid, Float:amount, weaponid, bodypart);
pawn Код:
while (start++ != end)
{
#emit PUSH.S weaponid
#emit PUSH.S amount
#emit PUSH.S issuerid
#emit PUSH.S playerid
#emit PUSH.C 16
#emit CONST.alt YSI_g_sCallbackAddresses
#emit LOAD.S.pri start
//#emit INC.pri
//#emit STOR.S.pri start
#emit LIDX
#emit MOVE.alt
#emit LCTRL 6
#emit ADD.C 24
#emit PUSH.pri
#emit MOVE.pri
#emit SCTRL 6
#emit MOVE.alt
#emit CONST.pri 0xFFFFFFFE
#emit AND
#emit PUSH.pri
#emit LOAD.S.pri ret
#emit AND
#emit POP.alt
#emit OR
#emit STOR.S.pri ret
if (ret < 0) return ret + 1;
}
pawn Код:
while (start++ != end)
{
#emit PUSH.S bodypart
#emit PUSH.S weaponid
#emit PUSH.S amount
#emit PUSH.S issuerid
#emit PUSH.S playerid
#emit PUSH.C 16
#emit CONST.alt YSI_g_sCallbackAddresses
#emit LOAD.S.pri start
//#emit INC.pri
//#emit STOR.S.pri start
#emit LIDX
#emit MOVE.alt
#emit LCTRL 6
#emit ADD.C 24
#emit PUSH.pri
#emit MOVE.pri
#emit SCTRL 6
#emit MOVE.alt
#emit CONST.pri 0xFFFFFFFE
#emit AND
#emit PUSH.pri
#emit LOAD.S.pri ret
#emit AND
#emit POP.alt
#emit OR
#emit STOR.S.pri ret
if (ret < 0) return ret + 1;
}
Find:
pawn Код:
public OnPlayerGiveDamage(playerid, damagedid, Float:amount, weaponid)
pawn Код:
public OnPlayerGiveDamage(playerid, damagedid, Float:amount, weaponid, bodypart)
pawn Код:
P:2("Hooks_OnPlayerGiveDamage called: %d, %d, %f, %d", playerid, damagedid, Float:amount, weaponid);
pawn Код:
P:2("Hooks_OnPlayerGiveDamage called: %d, %d, %f, %d, %d", playerid, damagedid, Float:amount, weaponid, bodypart);
pawn Код:
while (start++ != end)
{
#emit PUSH.S weaponid
#emit PUSH.S amount
#emit PUSH.S damagedid
#emit PUSH.S playerid
#emit PUSH.C 16
#emit CONST.alt YSI_g_sCallbackAddresses
#emit LOAD.S.pri start
//#emit INC.pri
//#emit STOR.S.pri start
#emit LIDX
#emit MOVE.alt
#emit LCTRL 6
#emit ADD.C 24
#emit PUSH.pri
#emit MOVE.pri
#emit SCTRL 6
#emit MOVE.alt
#emit CONST.pri 0xFFFFFFFE
#emit AND
#emit PUSH.pri
#emit LOAD.S.pri ret
#emit AND
#emit POP.alt
#emit OR
#emit STOR.S.pri ret
if (ret < 0) return ret + 1;
}
pawn Код:
while (start++ != end)
{
#emit PUSH.S bodypart
#emit PUSH.S weaponid
#emit PUSH.S amount
#emit PUSH.S damagedid
#emit PUSH.S playerid
#emit PUSH.C 16
#emit CONST.alt YSI_g_sCallbackAddresses
#emit LOAD.S.pri start
//#emit INC.pri
//#emit STOR.S.pri start
#emit LIDX
#emit MOVE.alt
#emit LCTRL 6
#emit ADD.C 24
#emit PUSH.pri
#emit MOVE.pri
#emit SCTRL 6
#emit MOVE.alt
#emit CONST.pri 0xFFFFFFFE
#emit AND
#emit PUSH.pri
#emit LOAD.S.pri ret
#emit AND
#emit POP.alt
#emit OR
#emit STOR.S.pri ret
if (ret < 0) return ret + 1;
}
Now go compile and have fun!