//Eredeti készítõ: PeteShag// Filterscriptet magyarította: A.S.S.A//=================//ezket a mód legelejére#include <a_samp>// SA-MP alapértelmezett include-ja#include <streamer>// Incognito által készített streamer include#include <zcmd>// Zeex által készített parancsfeldolgozó#include <foreach>// y_Less által készített include//=================//#define MAX_DROP_ITEMS 1000// Maximálisan egyszerre ennyi fegyver lehet eldobva#define COLOR_ACTION 0xFFC0CBFF// Rózsaszín//=================//new string[128], sendername[MAX_PLAYER_NAME], DropObject[MAX_DROP_ITEMS];//=================//enum dData //mód elejére{ DropGunAmmount[2],// ModellID és Töltény Float:DropGunPosX, Float:DropGunPosY, Float:DropGunPosZ, DropGunVWorld, DropGunInterior,};new DropInfo[MAX_DROP_ITEMS][dData];////mod elejére//=================//new GunObjectIDs[200] ={ 1575, 331, 333, 334, 335, 336, 337, 338, 339, 341, 321, 322, 323, 324, 325, 326, 342, 343, 344, -1, -1 , -1 , 346, 347, 348, 349, 350, 351, 352, 353, 355, 356, 372, 357, 358, 359, 360, 361, 362, 363, 364, 365, 366, 367, 368, 369, 1575};//=================//public OnFilterScriptInit()///nem tettem be { print(\"\\n--------------------------------------\"); print(\"Fegyver eldobó script by Peteshag... Filterscript betöltve!!!\"); print(\"--------------------------------------\\n\"); return 1;}//=================//stock GetGunObjectID(WeaponID)//ez is publicok alá ment{ if (WeaponID < 0 || WeaponID > 64) { return 1575; } return GunObjectIDs[WeaponID];}//=================//stock DropGun(playerid, GunID, GunAmmo, Float:X, Float:Y, Float:Z, world, interior)///ez is publicoc alá ment{ new name[MAX_PLAYER_NAME]; GetPlayerName(playerid,name,sizeof(name)); if(GunID != 0 && GunAmmo != 0) { for(new i = 0; i < sizeof(DropInfo); i++) { if(DropInfo[DropGunPosX] == 0.0 && DropInfo[DropGunPosY] == 0.0 && DropInfo[DropGunPosZ] == 0.0) { DropInfo[DropGunAmmount][0] = GunID; DropInfo[DropGunAmmount][1] = GunAmmo; DropInfo[DropGunPosX] = X; DropInfo[DropGunPosY] = Y; DropInfo[DropGunPosZ] = Z; DropInfo[DropGunVWorld] = world; DropInfo[DropGunInterior] = interior; DropObject = CreateDynamicObject(GetGunObjectID(GunID), X, Y, Z-1, 80.0, 0.0, 0.0, world); return 1; } } return 1; } return 1;}//=================//stock RemovePlayerWeapon(playerid, weaponid)//Létrejöttét segítette: Xalphon///ezt publicochoz tettembe{ if(!IsPlayerConnected(playerid) || weaponid < 0 || weaponid > 50) return; new saveweapon[13], saveammo[13]; for(new slot = 0; slot < 13; slot++) GetPlayerWeaponData(playerid, slot, saveweapon[slot], saveammo[slot]); ResetPlayerWeapons(playerid); for(new slot; slot < 13; slot++) { if(saveweapon[slot] == weaponid || saveammo[slot] == 0) continue; GivePlayerWeapon(playerid, saveweapon[slot], saveammo[slot]); } GivePlayerWeapon(playerid, 0, 1);}//=================//public OnFilterScriptExit()////ezt nem tettem be mert fölösleges{ print(\"Fegyver eldobó script by PeteShag... Filterscript kikapcsol!!! \"); return 1;}//=================//public OnPlayerDeath(playerid, killerid, reason)///ezt beillesztettem így ahogy van { new Float:X,Float:Y,Float:Z; GetPlayerPos(playerid, X, Y, Z); DropGun(playerid, GetPlayerWeapon(playerid),GetPlayerAmmo(playerid),X,Y,Z,GetPlayerVirtualWorld(playerid), GetPlayerInterior(playerid)); return 1;}//=================//command(dropgun, playerid, params[])///if(strcmp(cmd, \"/fegyvereldob\") || strcmp(cmd, \"/fegyver-eldob\")){ new Float:X,Float:Y,Float:Z; new GunID = GetPlayerWeapon(playerid); new GunAmmo = GetPlayerAmmo(playerid); GetPlayerName(playerid, sendername, sizeof(sendername)); GetPlayerPos(playerid, X, Y, Z); RemovePlayerWeapon(playerid, GunID); DropGun(playerid, GunID,GunAmmo,X,Y,Z,GetPlayerVirtualWorld(playerid),GetPlayerInterior(playerid)); format(string, sizeof(string), \"* %s ledobott egy fegyvert a földre.\", sendername); SendLocalMessage(playerid, string, 10.0, COLOR_ACTION, COLOR_ACTION); return 1;}//=================//command(pickupgun, playerid, params[])/////ezt átírtam erre if(strcmp(cmd, \"/fegyverfelvesz\") || strcmp(cmd, \"/fegyver-felvesz\")){ for(new i = 0; i < sizeof(DropInfo); i++) { if (IsPlayerInRangeOfPoint(playerid, 2.0,DropInfo[DropGunPosX],DropInfo[DropGunPosY],DropInfo[DropGunPosZ])) { if(GetPlayerVirtualWorld(playerid) == DropInfo[DropGunVWorld] && GetPlayerInterior(playerid) == DropInfo[DropGunVWorld]) { GetPlayerName(playerid, sendername, sizeof(sendername)); DestroyDynamicObject(DropObject); DropInfo[DropGunPosX] = 0.0; DropInfo[DropGunPosY] = 0.0; DropInfo[DropGunPosZ] = 0.0; DropInfo[DropGunAmmount][0] = 0; DropInfo[DropGunAmmount][1] = 0; GivePlayerWeapon(playerid,DropInfo[DropGunAmmount][0],DropInfo[DropGunAmmount][1]); format(string, sizeof(string), \"* %s felvett egy fegyvert a földrõl.\", sendername); SendLocalMessage(playerid, string, 10.0, COLOR_ACTION, COLOR_ACTION); return 1; } } } return 1;}//=================//stock SendLocalMessage(playerid, msg[], Float:MessageRange, Range1color, Range2color){ new Float: PlayerX, Float: PlayerY, Float: PlayerZ; GetPlayerPos(playerid, PlayerX, PlayerY, PlayerZ); foreach (Player, i) { if(IsPlayerInRangeOfPoint(i, MessageRange, PlayerX, PlayerY,PlayerZ)) { SendClientMessage(i, Range1color, msg); } else if(IsPlayerInRangeOfPoint(i, MessageRange/2.0, PlayerX, PlayerY,PlayerZ)) { SendClientMessage(i, Range2color, msg); } }}
//Eredeti készítõ: PeteShag// Filterscriptet magyarította: A.S.S.A//=================//ezket a mód legelejére#include <a_samp>// SA-MP alapértelmezett include-ja#include <streamer>// Incognito által készített streamer include#include <zcmd>// Zeex által készített parancsfeldolgozó#include <foreach>// y_Less által készített include//=================//#define MAX_DROP_ITEMS 1000// Maximálisan egyszerre ennyi fegyver lehet eldobva#define COLOR_ACTION 0xFFC0CBFF// Rózsaszín//=================//new string[128], sendername[MAX_PLAYER_NAME], DropObject[MAX_DROP_ITEMS];//=================//enum dData //mód elejére{ DropGunAmmount[2],// ModellID és Töltény Float:DropGunPosX, Float:DropGunPosY, Float:DropGunPosZ, DropGunVWorld, DropGunInterior,};new DropInfo[MAX_DROP_ITEMS][dData];////mod elejére//=================//new GunObjectIDs[200] ={ 1575, 331, 333, 334, 335, 336, 337, 338, 339, 341, 321, 322, 323, 324, 325, 326, 342, 343, 344, -1, -1 , -1 , 346, 347, 348, 349, 350, 351, 352, 353, 355, 356, 372, 357, 358, 359, 360, 361, 362, 363, 364, 365, 366, 367, 368, 369, 1575};//=================//public OnFilterScriptInit()///nem tettem be { print(\"\\n--------------------------------------\"); print(\"Fegyver eldobó script by Peteshag... Filterscript betöltve!!!\"); print(\"--------------------------------------\\n\"); return 1;}//=================//stock GetGunObjectID(WeaponID)//ez is publicok alá ment{ if (WeaponID < 0 || WeaponID > 64) { return 1575; } return GunObjectIDs[WeaponID];}//=================//stock DropGun(playerid, GunID, GunAmmo, Float:X, Float:Y, Float:Z, world, interior)///ez is publicoc alá ment{ new name[MAX_PLAYER_NAME]; GetPlayerName(playerid,name,sizeof(name)); if(GunID != 0 && GunAmmo != 0) { for(new i = 0; i < sizeof(DropInfo); i++) { if(DropInfo[DropGunPosX] == 0.0 && DropInfo[DropGunPosY] == 0.0 && DropInfo[DropGunPosZ] == 0.0) { DropInfo[DropGunAmmount][0] = GunID; DropInfo[DropGunAmmount][1] = GunAmmo; DropInfo[DropGunPosX] = X; DropInfo[DropGunPosY] = Y; DropInfo[DropGunPosZ] = Z; DropInfo[DropGunVWorld] = world; DropInfo[DropGunInterior] = interior; DropObject = CreateDynamicObject(GetGunObjectID(GunID), X, Y, Z-1, 80.0, 0.0, 0.0, world); return 1; } } return 1; } return 1;}//=================//public OnFilterScriptExit()////ezt nem tettem be mert fölösleges{ print(\"Fegyver eldobó script by PeteShag... Filterscript kikapcsol!!! \"); return 1;}//=================//public OnPlayerDeath(playerid, killerid, reason)///ezt beillesztettem így ahogy van { new Float:X,Float:Y,Float:Z; GetPlayerPos(playerid, X, Y, Z); DropGun(playerid, GetPlayerWeapon(playerid),GetPlayerAmmo(playerid),X,Y,Z,GetPlayerVirtualWorld(playerid), GetPlayerInterior(playerid)); return 1;}//=================//command(dropgun, playerid, params[])///if(strcmp(cmd, \"/fegyvereldob\") || strcmp(cmd, \"/fegyver-eldob\")){ new Float:X,Float:Y,Float:Z; new GunID = GetPlayerWeapon(playerid); new GunAmmo = GetPlayerAmmo(playerid); GetPlayerName(playerid, sendername, sizeof(sendername)); GetPlayerPos(playerid, X, Y, Z); RemovePlayerWeapon(playerid, GunID); DropGun(playerid, GunID,GunAmmo,X,Y,Z,GetPlayerVirtualWorld(playerid),GetPlayerInterior(playerid)); format(string, sizeof(string), \"* %s ledobott egy fegyvert a földre.\", sendername); SendLocalMessage(playerid, string, 10.0, COLOR_ACTION, COLOR_ACTION); return 1;}//=================//stock RemovePlayerWeapon(playerid, weaponid)//Létrejöttét segítette: Xalphon///ezt publicochoz tettembe{ if(!IsPlayerConnected(playerid) || weaponid < 0 || weaponid > 50) return; new saveweapon[13], saveammo[13]; for(new slot = 0; slot < 13; slot++) GetPlayerWeaponData(playerid, slot, saveweapon[slot], saveammo[slot]); ResetPlayerWeapons(playerid); for(new slot; slot < 13; slot++) { if(saveweapon[slot] == weaponid || saveammo[slot] == 0) continue; GivePlayerWeapon(playerid, saveweapon[slot], saveammo[slot]); } GivePlayerWeapon(playerid, 0, 1);}//=================//command(pickupgun, playerid, params[])/////ezt átírtam erre if(strcmp(cmd, \"/fegyverfelvesz\") || strcmp(cmd, \"/fegyver-felvesz\")){ for(new i = 0; i < sizeof(DropInfo); i++) { if (IsPlayerInRangeOfPoint(playerid, 2.0,DropInfo[DropGunPosX],DropInfo[DropGunPosY],DropInfo[DropGunPosZ])) { if(GetPlayerVirtualWorld(playerid) == DropInfo[DropGunVWorld] && GetPlayerInterior(playerid) == DropInfo[DropGunVWorld]) { GetPlayerName(playerid, sendername, sizeof(sendername)); DestroyDynamicObject(DropObject); DropInfo[DropGunPosX] = 0.0; DropInfo[DropGunPosY] = 0.0; DropInfo[DropGunPosZ] = 0.0; DropInfo[DropGunAmmount][0] = 0; DropInfo[DropGunAmmount][1] = 0; GivePlayerWeapon(playerid,DropInfo[DropGunAmmount][0],DropInfo[DropGunAmmount][1]); format(string, sizeof(string), \"* %s felvett egy fegyvert a földrõl.\", sendername); SendLocalMessage(playerid, string, 10.0, COLOR_ACTION, COLOR_ACTION); return 1; } } } return 1;}//=================//stock SendLocalMessage(playerid, msg[], Float:MessageRange, Range1color, Range2color){ new Float: PlayerX, Float: PlayerY, Float: PlayerZ; GetPlayerPos(playerid, PlayerX, PlayerY, PlayerZ); foreach (Player, i) { if(IsPlayerInRangeOfPoint(i, MessageRange, PlayerX, PlayerY,PlayerZ)) { SendClientMessage(i, Range1color, msg); } else if(IsPlayerInRangeOfPoint(i, MessageRange/2.0, PlayerX, PlayerY,PlayerZ)) { SendClientMessage(i, Range2color, msg); } }}