Skocz do zawartości

Witamy w Nieoficjalnym polskim support'cie AMX Mod X

Witamy w Nieoficjalnym polskim support'cie AMX Mod X, jak w większości społeczności internetowych musisz się zarejestrować aby móc odpowiadać lub zakładać nowe tematy, ale nie bój się to jest prosty proces w którym wymagamy minimalnych informacji.
  • Rozpoczynaj nowe tematy i odpowiedaj na inne
  • Zapisz się do tematów i for, aby otrzymywać automatyczne uaktualnienia
  • Dodawaj wydarzenia do kalendarza społecznościowego
  • Stwórz swój własny profil i zdobywaj nowych znajomych
  • Zdobywaj nowe doświadczenia

Dołączona grafika Dołączona grafika

Guest Message by DevFuse
 

Zdjęcie

Problem ze zmiana "mocy" odznak BF2Pomocy!!


  • Nie możesz napisać tematu
  • Zaloguj się, aby dodać odpowiedź
Brak odpowiedzi do tego tematu

#1 wilq1111

    Nowy

  • Użytkownik

Reputacja: 0
Nowy

  • Postów:5
  • Lokalizacja:RuRa
Offline

Napisano 03.02.2012 15:02

Nie mam pojecia jak zmienic te moce w tym plikach, co mam zmieniac/edytowac ??? nie wiem o co chodzi a potrzebuje zmienic. Teraz chodzi mi o wieksza niewidzialnosc z nozem, wiec proszę o pomoc ;)

uzywam tego moda http://amxx.pl/topic...nk-mod-pl-v110/

To jest badgepowers.inl a nizej pod tym dalem ham.inl poniewaz nie wiem w ktorym nawet z tych 2 sie to robi, pomocy!
Tylko nie zmieniajcie i nie pokazujcie mi gotowego jak mozecie to wyjasnijcie mi ktore i gdzie i o co chodzi ;)

//Bf2 Rank Mod badge powers File
//Contains all the power giving etc checking functions.

#if defined bf2_powers_included
#endinput
#endif
#define bf2_powers_included

public set_speed(id)
{
if ( !get_pcvar_num(gPcvarBadgesActive) || !get_pcvar_num(gPcvarBadgePowers) ) return;
if ( !is_user_alive(id) || freezetime ) return;

new Float:speed;

if ( g_imobile[id] )
{
speed = 100.0;
}
else
{
if ( fm_get_user_vip(id) )
{
//VIPs only have 1 speed no matter the weapon
speed = 227.0;
}
else
{
new weapon = get_user_weapon(id);

speed = gCSWeaponSpeed[weapon];

if ( gCurrentFOV[id] <= 45 )
{
switch(weapon)
{
case CSW_SCOUT: speed = 220.0;
case CSW_SG550, CSW_AWP, CSW_G3SG1: speed = 150.0;
}
}
}

new smglevel = g_PlayerBadges[id][BADGE_SMG];
if ( smglevel )
{
//15 units faster per level.
speed += (smglevel * 15.0);
}
}

if ( speed != fm_get_user_maxspeed(id) )
{
fm_set_user_maxspeed(id, speed);
}
}

public set_invis(id)
{
if ( !get_pcvar_num(gPcvarBadgesActive) || !get_pcvar_num(gPcvarBadgePowers) ) return;
if ( !is_user_alive(id) ) return;

new shotgunlevel = g_PlayerBadges[id][BADGE_SHOTGUN];

if ( shotgunlevel && get_user_weapon(id) == CSW_KNIFE )
{
fm_set_rendering(id, kRenderFxNone, 0, 0, 0, kRenderTransTexture, gInvisAlphaValue[shotgunlevel-1]);
g_invis[id] = true;
}
else
{
fm_set_rendering(id);
g_invis[id] = false;
}
}

public remove_imobile(id)
{
g_imobile[id] = false;

set_speed(id);
}

public give_userweapon(id)
{
if ( !get_pcvar_num(gPcvarBadgesActive) || !get_pcvar_num(gPcvarBadgePowers) ) return;
if ( !is_user_alive(id) ) return;

new bool:givenitem = false;

new assaultlevel = g_PlayerBadges[id][BADGE_ASSAULT];
if ( assaultlevel )
{
new hp;
hp = 100 + (assaultlevel*10);

if ( get_user_health(id) < hp )
{
fm_set_user_health(id, hp);

if ( pev(id, pev_max_health) < float(hp) )
{
set_pev(id, pev_max_health, float(hp));
}

givenitem = true;
}
}

new sniperlevel = g_PlayerBadges[id][BADGE_SNIPER];

if ( sniperlevel )
{
if ( random_num(1, (5-sniperlevel)) == 1 )
{
new weaponName[32];
new weaponID = get_user_weapon(id);

if ( !get_pcvar_num(gPcvarFreeAwp) )
{
fm_give_item(id, "weapon_scout");
}
else
{
fm_give_item(id, "weapon_awp");
}

if ( weaponID )
{
get_weaponname(weaponID, weaponName, charsmax(weaponName));
engclient_cmd(id, weaponName);
}

givenitem = true;
}
}

new explosionlevel = g_PlayerBadges[id][BADGE_EXPLOSIVES];

if ( explosionlevel )
{
if ( random_num(1, (5-explosionlevel)) == 1 )
{
fm_give_item(id, "weapon_hegrenade");
givenitem = true;
}
}

switch (numofbadges[id])
{
case 6 .. 11:
{
if ( fm_get_user_armor(id) < 50 )
{
fm_set_user_armor(id, 50);
givenitem = true;
}
}

case 12 .. 18:
{
if ( fm_get_user_armor(id) < 100 )
{
fm_set_user_armor(id, 100);
givenitem = true;
}
}

case 19 .. 24:
{
if ( fm_get_user_armor(id) < 150 )
{
fm_set_user_armor(id, 150);
givenitem = true;
}
}

case 25 .. 29:
{
if ( fm_get_user_armor(id) < 200 )
{
fm_set_user_armor(id, 200);
givenitem = true;
}
}

case 30 .. 34:
{
if ( fm_get_user_armor(id) < 250 )
{
fm_set_user_armor(id, 250);
givenitem = true;
}
}
}

if ( givenitem )
screen_flash(id, 0, 255, 0, 100); //Green screen flash
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1045\\ f0\\ fs16 \n\\ par }
*/

Ham.inl

//Bf2 Rank Mod hamsandwich File
//Contains all the Ham Sandwich functions.

#if defined bf2_ham_included
#endinput
#endif
#define bf2_ham_included

//Called on task from client_putinserver
public RegisterHam_CZBot(id)
{
// Thx to Avalanche and GunGame for which this method is based on.
if ( gCZBotRegisterHam || !is_user_connected(id) ) return;

// Make sure it's a bot and if quota greater than 0 it's a cz bot.
if ( gPcvarBotQuota && get_pcvar_num(gPcvarBotQuota) > 0 && is_user_bot(id) ) {
// Post-spawn fix for cz bots, since RegisterHam does not work for them.
RegisterHamFromEntity(Ham_Spawn, id, "Ham_Spawn_Post", 1);
RegisterHamFromEntity(Ham_TakeDamage, id, "Ham_TakeDamage_Pre");

gCZBotRegisterHam = true;

// Incase this CZ bot was spawned alive during a round, call the Ham_Spawn
// because it would have happened before the RegisterHam.
if ( is_user_alive(id) ) Ham_Spawn_Post(id);
}
}

public Ham_Spawn_Post(id)
{
if ( !get_pcvar_num(gPcvarBF2Active) ) return HAM_IGNORED;

// Verify the client is not just put in server but is alive
if ( !is_user_alive(id) ) return HAM_IGNORED;

// Make sure this is not a bot creation before it spawns
if ( fm_get_user_team(id) == CS_TEAM_UNASSIGNED ) return HAM_IGNORED;

check_level(id);

// Task is needed because sometimes when survived round StatusText gets cleared on spawn
set_task(0.1, "DisplayHUD", id);

if ( !get_pcvar_num(gPcvarBadgesActive) || !get_pcvar_num(gPcvarBadgePowers) ) return HAM_IGNORED;

set_invis(id);

set_task(0.5, "give_userweapon", id);
set_task(0.6, "set_speed", id);

return HAM_IGNORED;
}

public Ham_TakeDamage_Pre(victim, inflictor, attacker, Float:damage, damagebits)
{
if ( !get_pcvar_num(gPcvarBadgesActive) || !get_pcvar_num(gPcvarBadgePowers) ) return HAM_IGNORED;
if ( !is_user_connected(attacker) || !is_user_alive(victim) ) return HAM_IGNORED;
if ( victim != attacker && fm_get_user_team(victim) == fm_get_user_team(attacker) && !get_pcvar_num(gPcvarFFA) ) return HAM_IGNORED;

new expBadgeLevel = g_PlayerBadges[attacker][BADGE_EXPLOSIVES];
new supBadgeLevel = g_PlayerBadges[attacker][BADGE_SUPPORT];

if ( expBadgeLevel && (damagebits & DMG_GRENADE) ) //Explosives badge, nade dmg
{
//multiply .2 nade damage per level
damage += damage * expBadgeLevel * 0.2;
}
else if ( supBadgeLevel && inflictor == attacker && get_user_weapon(attacker) == CSW_M249 ) //Support badge, bonus damg
{
//add to 2 m249 damage per level
damage += supBadgeLevel * 2.0;
}
else
{
return HAM_IGNORED;
}

SetHamParamFloat(4, damage);

return HAM_HANDLED;
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1045\\ f0\\ fs16 \n\\ par }
*/

Użytkownik wilq1111 edytował ten post 03.02.2012 15:04

  • +
  • -
  • 0




Użytkownicy przeglądający ten temat: 0

0 użytkowników, 0 gości, 0 anonimowych