hlmod.hu

Magyar Half-Life Mód közösség!
Pontos idő: 2025.06.16. 21:48



Jelenlévő felhasználók

Jelenleg 379 felhasználó van jelen :: 1 regisztrált, 0 rejtett és 378 vendég

A legtöbb felhasználó (2761 fő) 2025.01.09. 20:06-kor tartózkodott itt.

Regisztrált felhasználók: Google [Bot]az elmúlt 5 percben aktív felhasználók alapján

Utoljára aktív
Ahhoz hogy lásd ki volt utoljára aktív, be kell jelentkezned.



Az oldal teljeskörű
használatához regisztrálj.

Regisztráció

Kereső


Új téma nyitása Hozzászólás a témához  [8 hozzászólás ] 
Szerző Üzenet
HozzászólásElküldve:2012.07.09. 10:43 
Offline
Őskövület
Avatar

Csatlakozott:2013.01.01. 17:48
Hozzászólások:2441
Megköszönt másnak: 18 alkalommal
Megköszönték neki: 21 alkalommal
Üdv.!

Ezt a Furien modot át tudja valaki írni úgy, hogy a Terroristáknak (Furieneknek) legyen a bal alsó sarkukba egy láthatóságmérő %-ban! +hogy ne csak steamosokat engedjen fel a plugin, hanem nseket is!!

Kód:
  1. /*      Formatright © 2009, ConnorMcLeod

  2.  

  3.         Furiens is free software;

  4.         you can redistribute it and/or modify it under the terms of the

  5.         GNU General Public License as published by the Free Software Foundation.

  6.  

  7.         This program is distributed in the hope that it will be useful,

  8.         but WITHOUT ANY WARRANTY; without even the implied warranty of

  9.         MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the

  10.         GNU General Public License for more details.

  11.  

  12.         You should have received a copy of the GNU General Public License

  13.         along with Furiens; if not, write to the

  14.         Free Software Foundation, Inc., 59 Temple Place - Suite 330,

  15.         Boston, MA 02111-1307, USA.

  16. */

  17.  

  18. #include <amxmodx>

  19. #include <cstrike>

  20. #include <engine>

  21. #include <fun>

  22. #include <fakemeta>

  23. #include <hamsandwich>

  24.  

  25. #include "furien.inc"

  26.  

  27. #define MAX_PLAYERS 32

  28.  

  29. #define Ham_Player_ResetMaxSpeed Ham_Item_PreFrame

  30.  

  31. new g_iMaxPlayers

  32. #define FIRST_PLAYER_ID 1

  33. #define IsPlayer(%1)    ( FIRST_PLAYER_ID <= %1 <= g_iMaxPlayers )

  34.  

  35. new CsTeams:g_iFuriensTeam = CS_TEAM_T

  36.  

  37. // players offsets

  38. #define XTRA_OFS_PLAYER 5

  39. #define m_iAccount 115

  40. #define cs_set_money_value(%1,%2)       set_pdata_int(%1, m_iAccount, %2, XTRA_OFS_PLAYER)

  41.  

  42. // "weaponbox" offsets

  43. #define XO_WEAPONBOX                            4

  44. #define m_rgpPlayerItems_wpnbx_Slot5    39

  45. #define IsWeaponBoxC4(%1)       ( get_pdata_cbase(%1, m_rgpPlayerItems_wpnbx_Slot5, XO_WEAPONBOX) > 0 )

  46.  

  47. new g_bShouldAnswerMenu, g_bCanModifyCvars

  48. #define MarkUserSeeMenu(%1)     g_bShouldAnswerMenu |= 1<<(%1&31)

  49. #define ClearUserSeeMenu(%1)    g_bShouldAnswerMenu &= ~(1<<(%1&31))

  50. #define ShouldUserSeeMenu(%1)   g_bShouldAnswerMenu & 1<<(%1&31)

  51.  

  52. #define MarkUserCvars(%1)       g_bCanModifyCvars |= 1<<(%1&31)

  53. #define ClearUserCvars(%1)      g_bCanModifyCvars &= ~(1<<(%1&31))

  54. #define CanUserCvars(%1)                g_bCanModifyCvars & 1<<(%1&31)

  55.  

  56. const CVARS_MENU_KEYS = (1<<0)|(1<<1)

  57.  

  58. new g_iFurienTeamChangeForward

  59.  

  60. new g_iFurienRoundRestartForward, bool:g_bRestarting

  61.  

  62. new Float:g_flFurienGravity = 0.375

  63. new g_iInvisFactor = 1

  64. new Float:g_flMaxSpeed = 500.0

  65. new g_iFurienReward = 1337

  66. new g_iAntiReward = 400

  67. new g_iAnnounce = 1

  68.  

  69. new bool:g_bSwitchTeam = true

  70. new bool:g_bSwitchInProgress

  71.  

  72. new Trie:g_tPreventEntityKeyvalue

  73. new g_iPickUp = 2

  74.  

  75. new g_szSpeedCommand[128]

  76.  

  77. new g_szFurienWinSound[64]

  78. new g_szAntiWinSound[64]

  79.  

  80. new g_szGameDescription[32]

  81.  

  82. new g_bitBombPlant

  83.  

  84. new g_iNewMoney

  85. new g_iMsgHookMoney

  86.  

  87. new g_iTextMsg, g_iMoney

  88.  

  89. new HamHook:g_iHhTakeDamage

  90.  

  91. public plugin_natives()

  92. {

  93.         register_library("furien")

  94.         register_native("furien_get_user_team", "fr_get_user_team")

  95. }

  96.  

  97. public plugin_precache()

  98. {

  99.         if( !ReadCfgFile() )

  100.         {

  101.                 log_amx("Configuration file doesn't exist !!")

  102.         }

  103. }

  104.  

  105. public plugin_init()

  106. {

  107.         register_plugin("Furiens", FURIEN_VERSION, "ConnorMcLeod")

  108.  

  109.         register_dictionary("common.txt")

  110.         register_dictionary("furiens.txt")

  111.  

  112.         new pCvar = register_cvar("furien_version", FURIEN_VERSION, FCVAR_SERVER|FCVAR_EXTDLL|FCVAR_SPONLY)

  113.         set_pcvar_string(pCvar, FURIEN_VERSION)

  114.  

  115.         register_clcmd("say ?", "A_Propos")

  116.         register_clcmd("say_team ?", "A_Propos")

  117.         register_clcmd("?", "A_Propos")

  118.  

  119.         register_menucmd(register_menuid("Furiens Cvars"), CVARS_MENU_KEYS, "CvarsMenuCallBack")

  120.  

  121.         RegisterHam(Ham_Spawn, "player", "Player_Spawn_Post", 1)

  122.         RegisterHam(Ham_Player_ResetMaxSpeed, "player", "Player_ResetMaxSpeed", 1)

  123.  

  124.         register_message(get_user_msgid("SendAudio"), "Message_SendAudio")

  125.  

  126.         new iEnt

  127.         iEnt = create_entity("info_target")

  128.         set_pev(iEnt, pev_classname, "check_speed")

  129.         set_pev(iEnt, pev_nextthink, get_gametime() + 0.1)

  130.         register_think("check_speed", "Set_Furiens_Visibility")

  131.  

  132.         iEnt = create_entity("info_target")

  133.         set_pev(iEnt, pev_classname, "check_cvars")

  134.         set_pev(iEnt, pev_nextthink, get_gametime() + 10.0)

  135.         register_think("check_cvars", "Check_Players_Cvars")

  136.  

  137.         g_iFurienTeamChangeForward = CreateMultiForward("furien_team_change", ET_IGNORE, FP_CELL)

  138.  

  139.         register_event("TextMsg", "Event_TextMsg_Restart", "a", "2&#Game_C", "2&#Game_w")

  140.         register_event("HLTV", "Event_HLTV_New_Round", "a", "1=0", "2=0")

  141.         g_iFurienRoundRestartForward = CreateMultiForward("furien_round_restart", ET_IGNORE)

  142.  

  143.         register_event("DeathMsg", "Event_DeathMsg", "a")

  144.  

  145.         if( get_cvar_float("sv_maxspeed") < g_flMaxSpeed )

  146.         {

  147.                 set_cvar_float("sv_maxspeed", g_flMaxSpeed)

  148.         }

  149.  

  150.         formatex(g_szSpeedCommand, charsmax(g_szSpeedCommand),

  151.                         ";cl_forwardspeed %.1f;cl_sidespeed %.1f;cl_backspeed %.1f",

  152.                                                         g_flMaxSpeed, g_flMaxSpeed, g_flMaxSpeed)

  153.  

  154.         g_iMaxPlayers = get_maxplayers()

  155.         g_iTextMsg = get_user_msgid("TextMsg")

  156.         g_iMoney = get_user_msgid("Money")

  157. }

  158.  

  159. ReadCfgFile()

  160. {

  161.         new szConfigFile[128]

  162.         get_localinfo("amxx_configsdir", szConfigFile, charsmax(szConfigFile))

  163.         format(szConfigFile, charsmax(szConfigFile), "%s/furien/furien.ini", szConfigFile);

  164.  

  165.         new fp = fopen(szConfigFile, "rt")

  166.         if( !fp )

  167.         {

  168.                 return 0

  169.         }

  170.  

  171.         new szDatas[96], szKey[16], szValue[64]

  172.         while( !feof(fp) )

  173.         {

  174.                 fgets(fp, szDatas, charsmax(szDatas))

  175.                 trim(szDatas)

  176.                 if(!szDatas[0] || szDatas[0] == ';' || szDatas[0] == '#' || (szDatas[0] == '/' && szDatas[1] == '/'))

  177.                 {

  178.                         continue

  179.                 }

  180.  

  181.                 parse(szDatas, szKey, charsmax(szKey), szValue, charsmax(szValue))

  182.  

  183.                 switch( szKey[0] )

  184.                 {

  185.                         case 'B':

  186.                         {

  187.                                 switch( szKey[1] )

  188.                                 {

  189.                                         case 'U':

  190.                                         {

  191.                                                 if( equal(szKey, "BUY") )

  192.                                                 {

  193.                                                         switch( clamp(str_to_num(szValue), 0, 1) )

  194.                                                         {

  195.                                                                 case 0:

  196.                                                                 {

  197.                                                                         new iEnt

  198.  

  199.                                                                         g_tPreventEntityKeyvalue = TrieCreate()

  200.                                                                         TrieSetCell(g_tPreventEntityKeyvalue, "player_weaponstrip", 1)

  201.                                                                         TrieSetCell(g_tPreventEntityKeyvalue, "game_player_equip", 1)

  202.                                                                         TrieSetCell(g_tPreventEntityKeyvalue, "info_map_parameters", 1)

  203.  

  204.                                                                         iEnt = create_entity("info_map_parameters")

  205.                                                                         DispatchKeyValue(iEnt, "buying", "3")

  206.                                                                         DispatchSpawn(iEnt)

  207.  

  208.                                                                         register_buy_cmd()

  209.                                                                 }

  210.                                                         }

  211.                                                 }

  212.                                         }

  213.                                         case 'O':

  214.                                         {

  215.                                                 if( equal(szKey, "BOMB_PLANT") )

  216.                                                 {

  217.                                                         g_bitBombPlant = clamp(str_to_num(szValue), 0, 3)

  218.                                                         if( g_bitBombPlant != 3 )

  219.                                                         {

  220.                                                                 RegisterHam(Ham_AddPlayerItem, "player", "Player_AddPlayerItem")

  221.                                                         }

  222.                                                 }

  223.                                         }

  224.                                 }

  225.                         }

  226.                         case 'F':

  227.                         {

  228.                                 if( equal(szKey, "FURIEN_ANNOUNCE") )

  229.                                 {

  230.                                         g_iAnnounce = str_to_num(szValue)

  231.                                 }

  232.                         }

  233.                         case 'G':

  234.                         {

  235.                                 switch( szKey[1] )

  236.                                 {

  237.                                         case 'A':

  238.                                         {

  239.                                                 if( equal(szKey, "GAMENAME") )

  240.                                                 {

  241.                                                         replace(szValue, charsmax(szValue), "%v", FURIEN_VERSION)

  242.                                                         copy(g_szGameDescription, charsmax(g_szGameDescription), szValue)

  243.                                                         register_forward(FM_GetGameDescription, "GetGameDescription")

  244.                                                 }

  245.                                         }

  246.                                         case 'R':

  247.                                         {

  248.                                                 if( equal(szKey, "GRAVITY") )

  249.                                                 {

  250.                                                         g_flFurienGravity = floatclamp(str_to_float(szValue), 0.0125, 1.0)

  251.                                                 }

  252.                                         }

  253.                                 }

  254.                         }

  255.                         case 'I':

  256.                         {

  257.                                 if( equal(szKey, "INVIS_FACTOR") )

  258.                                 {

  259.                                         g_iInvisFactor = clamp(str_to_num(szValue), 1, 4)

  260.                                 }

  261.                         }

  262.                         case 'K':

  263.                         {

  264.                                 switch( szKey[5] )

  265.                                 {

  266.                                         case 'A':

  267.                                         {

  268.                                                 if( equal(szKey, "KILL_ANTI_REWARD") )

  269.                                                 {

  270.                                                         g_iAntiReward = str_to_num(szValue)

  271.                                                 }

  272.                                         }

  273.                                         case 'F':

  274.                                         {

  275.                                                 if( equal(szKey, "KILL_FURIEN_REWARD") )

  276.                                                 {

  277.                                                         g_iFurienReward = str_to_num(szValue)

  278.                                                 }

  279.                                         }

  280.                                 }

  281.                         }

  282.                         case 'M':

  283.                         {

  284.                                 if( equal(szKey, "MAXSPEED") )

  285.                                 {

  286.                                         g_flMaxSpeed = floatclamp(str_to_float(szValue), 100.0, 2000.0)

  287.                                 }

  288.                         }

  289.                         case 'P':

  290.                         {

  291.                                 if( equal(szKey, "PICK_UP") )

  292.                                 {

  293.                                         g_iPickUp = clamp(str_to_num(szValue), 0, 3)

  294.                                         switch( g_iPickUp )

  295.                                         {

  296.                                                 case 0,1,2:

  297.                                                 {

  298.                                                         RegisterHam(Ham_Touch, "weaponbox", "CWeaponBox_Touch")

  299.                                                         RegisterHam(Ham_Touch, "armoury_entity", "GroundWeapon_Touch")

  300.                                                         RegisterHam(Ham_Touch, "weapon_shield", "GroundWeapon_Touch")

  301.                                                 }

  302.                                         }

  303.                                 }

  304.                         }

  305.                         case 'S':

  306.                         {

  307.                                 if( equal(szKey, "SWITCH_TEAMS") )

  308.                                 {

  309.                                         g_bSwitchTeam = !!clamp(str_to_num(szValue), 0, 1)

  310.                                         if( g_bSwitchTeam )

  311.                                         {

  312.                                                 g_iHhTakeDamage = RegisterHam(Ham_TakeDamage, "player", "Player_TakeDamage")

  313.                                                 DisableHamForward( g_iHhTakeDamage )

  314.                                         }

  315.                                 }

  316.                         }

  317.                         case 'W':

  318.                         {

  319.                                 if( equal(szKey, "WIN_SOUND_", 10) )

  320.                                 {

  321.                                         new szFullPath[128]

  322.                                         switch(szKey[10])

  323.                                         {

  324.                                                 case 'F':

  325.                                                 {

  326.                                                         formatex(szFullPath, charsmax(szFullPath), "sound/%s", szValue)

  327.                                                         if( file_exists(szFullPath) )

  328.                                                         {

  329.                                                                 copy(g_szFurienWinSound, charsmax(g_szFurienWinSound), szValue)

  330.                                                                 precache_sound(szValue)

  331.                                                         }

  332.                                                 }

  333.                                                 case 'A':

  334.                                                 {

  335.                                                         formatex(szFullPath, charsmax(szFullPath), "sound/%s", szValue)

  336.                                                         if( file_exists(szFullPath) )

  337.                                                         {

  338.                                                                 copy(g_szAntiWinSound, charsmax(g_szAntiWinSound), szValue)

  339.                                                                 precache_sound(szValue)

  340.                                                         }

  341.                                                 }

  342.                                         }

  343.                                 }

  344.                         }

  345.                 }

  346.         }

  347.         fclose( fp )

  348.  

  349.         return 1

  350. }

  351.  

  352. public GetGameDescription()

  353. {

  354.         forward_return(FMV_STRING, g_szGameDescription)

  355.         return FMRES_SUPERCEDE

  356. }

  357.  

  358. public Event_TextMsg_Restart()

  359. {

  360.         g_bRestarting = true

  361. }

  362.  

  363. public Event_HLTV_New_Round()

  364. {

  365.         if( g_bRestarting )

  366.         {

  367.                 g_bRestarting = false

  368.                 new iRet

  369.                 ExecuteForward(g_iFurienRoundRestartForward, iRet)

  370.         }

  371.  

  372.         if( g_bSwitchInProgress )

  373.         {

  374.                 g_bSwitchInProgress = false

  375.                 DisableHamForward( g_iHhTakeDamage )

  376.         }

  377. }

  378.  

  379. public GroundWeapon_Touch(iWeapon, id)

  380. {

  381.         if( IsPlayer(id) )

  382.         {

  383.                 if( !g_iPickUp )

  384.                 {

  385.                         remove_entity(iWeapon)

  386.                         return HAM_SUPERCEDE

  387.                 }

  388.  

  389.                 if( !is_user_alive(id) )

  390.                 {

  391.                         return HAM_SUPERCEDE

  392.                 }

  393.  

  394.                 new iTeam = __get_user_team(id)

  395.                 if(     ( iTeam == -1 )

  396.                 ||      (iTeam == Furien && g_iPickUp != 1)

  397.                 ||      (iTeam == AntiFurien && g_iPickUp != 2) )

  398.                 {

  399.                         return HAM_SUPERCEDE

  400.                 }

  401.         }

  402.         return HAM_IGNORED

  403. }

  404.  

  405. public CWeaponBox_Touch(iWeaponBox, id)

  406. {

  407.         if( IsPlayer(id) )

  408.         {

  409.                 if( !is_user_alive(id) )

  410.                 {

  411.                         return HAM_SUPERCEDE

  412.                 }

  413.  

  414.                 if( IsWeaponBoxC4(iWeaponBox) )

  415.                 {

  416.                         return HAM_IGNORED

  417.                 }

  418.  

  419.                 if( !g_iPickUp )

  420.                 {

  421.                         remove_entity(iWeaponBox)

  422.                         return HAM_SUPERCEDE

  423.                 }

  424.  

  425.                 new iTeam = __get_user_team(id)

  426.                 if(     ( iTeam == -1 )

  427.                 ||      (iTeam == Furien && g_iPickUp != 1)

  428.                 ||      (iTeam == AntiFurien && g_iPickUp != 2) )

  429.                 {

  430.                         return HAM_SUPERCEDE

  431.                 }

  432.         }

  433.         return HAM_IGNORED

  434. }

  435.  

  436. register_buy_cmd()

  437. {

  438.         register_clcmd("buy", "ClientCommand_Buy")

  439.         register_clcmd("bUy", "ClientCommand_Buy")

  440.         register_clcmd("buY", "ClientCommand_Buy")

  441.         register_clcmd("bUY", "ClientCommand_Buy")

  442.         register_clcmd("Buy", "ClientCommand_Buy")

  443.         register_clcmd("BUy", "ClientCommand_Buy")

  444.         register_clcmd("BuY", "ClientCommand_Buy")

  445.         register_clcmd("BUY", "ClientCommand_Buy")

  446. }

  447.  

  448. public ClientCommand_Buy(id)

  449. {

  450.         return PLUGIN_HANDLED_MAIN

  451. }

  452.  

  453. public pfn_keyvalue( iEnt )

  454. {

  455.         if( g_tPreventEntityKeyvalue )

  456.         {

  457.                 new szClassName[32], szCrap[2]

  458.                 copy_keyvalue(szClassName, charsmax(szClassName), szCrap, charsmax(szCrap), szCrap, charsmax(szCrap))

  459.                 if( TrieKeyExists(g_tPreventEntityKeyvalue, szClassName) )

  460.                 {

  461.                         remove_entity(iEnt)

  462.                         return PLUGIN_HANDLED

  463.                 }

  464.         }

  465.         return PLUGIN_CONTINUE

  466. }

  467.  

  468. public plugin_cfg()

  469. {

  470.         if( g_tPreventEntityKeyvalue )

  471.         {

  472.                 TrieDestroy(g_tPreventEntityKeyvalue)

  473.                 set_cvar_float("sv_restart", 1.0)

  474.         }

  475. }

  476.  

  477. public fr_get_user_team(/*iPlugin, iParams*/)

  478. {

  479.         return __get_user_team( get_param(1) )

  480. }

  481.  

  482. __get_user_team(id)

  483. {

  484.         new CsTeams:iTeam = cs_get_user_team(id)

  485.         if( CS_TEAM_T <= iTeam <= CS_TEAM_CT )

  486.         {

  487.                 if( iTeam == g_iFuriensTeam )

  488.                 {

  489.                         return Furien

  490.                 }

  491.                 return AntiFurien

  492.         }

  493.         return -1

  494. }

  495.  

  496. public client_connect(id)

  497. {


  498.         query_client_cvar(id, "gl_clear", "Client_Cvar_Result")

  499. }

  500.  

  501. public Client_Cvar_Result(id, const szCvar[], const szValue[])

  502. {

  503.         if( szValue[0] == 'B' )

  504.         {

  505.                 server_cmd("kick #%d Software video mode forbidden !! Acceleration logicielle interdite !!", get_user_userid(id))

  506.         }

  507. }

  508.  

  509. public client_putinserver( id )

  510. {

  511.         MarkUserSeeMenu( id )

  512.         ClearUserCvars( id )

  513.  

  514.         if( g_iAnnounce )

  515.         {

  516.                 set_task(random_float(11.0, 19.0), "A_Propos", id)

  517.         }

  518. }

  519.  

  520. public Player_Spawn_Post( id )

  521. {

  522.         if( is_user_alive(id) )

  523.         {

  524.                 if( ShouldUserSeeMenu(id) )

  525.                 {

  526.                         ShowSpeedCvarsMenu(id)

  527.                 }

  528.  

  529.                 strip_user_weapons(id)

  530.  

  531.                 if( __get_user_team(id) == Furien )

  532.                 {

  533.                         set_user_gravity(id, g_flFurienGravity)

  534.                         set_user_footsteps(id, 1)

  535.                 }

  536.                 else

  537.                 {

  538.                         set_user_footsteps(id, 0)

  539.                         set_user_gravity(id, 1.0)

  540.                 }

  541.  

  542.                 set_user_rendering(id, kRenderFxNone, 0, 0, 0, kRenderNormal, 0)

  543.         }

  544. }

  545.  

  546. ShowSpeedCvarsMenu(id)

  547. {

  548.         new szMenu[256], n

  549.         n += formatex(szMenu[n], charsmax(szMenu)-n, "%L^n", id, "FURIEN_MENU_CVAR")

  550.         n += formatex(szMenu[n], charsmax(szMenu)-n, "^n\y1\w. %L", id, "YES")

  551.         n += formatex(szMenu[n], charsmax(szMenu)-n, "^n\y2\w. %L", id, "NO")

  552.  

  553.         show_menu(id, CVARS_MENU_KEYS, szMenu, -1, "Furiens Cvars")

  554. }

  555.  

  556. public CvarsMenuCallBack(id, iKey)

  557. {

  558.         switch( iKey )

  559.         {

  560.                 case 0:

  561.                 {

  562.                         MarkUserCvars( id )

  563.                         ClearUserSeeMenu( id )

  564.                 }

  565.                 case 1:

  566.                 {

  567.                         ClearUserCvars( id )

  568.                 }

  569.         }

  570.         return PLUGIN_HANDLED

  571. }

  572.  

  573. public Player_ResetMaxSpeed( id )

  574. {

  575.         if( is_user_alive(id) && __get_user_team(id) == Furien && get_user_maxspeed(id) != 1.0 )

  576.         {

  577.                 set_pev(id, pev_maxspeed, g_flMaxSpeed)

  578.         }

  579. }

  580.  

  581. public Check_Players_Cvars( iEnt )

  582. {

  583.         entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 5.0)

  584.  

  585.         new iPlayers[MAX_PLAYERS], iNum, id

  586.         get_players(iPlayers, iNum, "ace", g_iFuriensTeam == CS_TEAM_T ? "TERRORIST" : "CT")

  587.         for(new i; i<iNum; i++)

  588.         {

  589.                 id = iPlayers[i]

  590.                 if( CanUserCvars( id ) )

  591.                 {

  592.                         query_client_cvar(id, "cl_forwardspeed", "CvarResult")

  593.                         query_client_cvar(id, "cl_backspeed", "CvarResult")

  594.                         query_client_cvar(id, "cl_sidespeed", "CvarResult")

  595.                 }

  596.         }

  597. }

  598.  

  599. public CvarResult(const id, const szCvar[], const szValue[])

  600. {

  601.         if( CanUserCvars( id ) && is_user_connected(id) && str_to_float(szValue) < g_flMaxSpeed )

  602.         {

  603.                 client_cmd(id, g_szSpeedCommand)

  604.         }

  605. }

  606.  

  607. public Set_Furiens_Visibility( iEnt )

  608. {

  609.         entity_set_float(iEnt, EV_FL_nextthink, get_gametime() + 0.1)

  610.  

  611.         new iPlayers[MAX_PLAYERS], iNum, id, Float:fVecVelocity[3], iSpeed

  612.  

  613.         get_players(iPlayers, iNum, "ae", g_iFuriensTeam == CS_TEAM_T ? "TERRORIST" : "CT")

  614.  

  615.         for(new i; i<iNum; i++)

  616.         {

  617.                 id = iPlayers[i]

  618.                 if( get_user_weapon(id) == CSW_KNIFE )

  619.                 {

  620.                         entity_get_vector(id, EV_VEC_velocity, fVecVelocity)

  621.                         iSpeed = floatround( vector_length(fVecVelocity) )

  622.                         if( iSpeed < g_iInvisFactor*255 )

  623.                         {

  624.                                 set_user_rendering(id, kRenderFxNone, 0, 0, 0, kRenderTransAlpha, iSpeed/g_iInvisFactor)

  625.                         }

  626.                         else

  627.                         {

  628.                                 set_user_rendering(id, kRenderFxNone, 0, 0, 0, kRenderNormal, 0)

  629.                         }

  630.                 }

  631.                 else

  632.                 {

  633.                         set_user_rendering(id, kRenderFxNone, 0, 0, 0, kRenderNormal, 0)

  634.                 }

  635.         }

  636. }

  637.  

  638. public Message_SendAudio(iMsgId, iMsgDest, id)

  639. {

  640.         if( !id )

  641.         {

  642.                 new bool:bAntiWins

  643.                 new bool:bSwitchTeams

  644.                 new szSound[14]

  645.                 get_msg_arg_string(2, szSound, charsmax(szSound))

  646.                 if( equal(szSound, "%!MRAD_ctwin") )

  647.                 {

  648.                         if( g_iFuriensTeam == CS_TEAM_T )

  649.                         {

  650.                                 if( g_bSwitchTeam )

  651.                                 {

  652.                                         bSwitchTeams = true

  653.                                         g_iFuriensTeam = CS_TEAM_CT

  654.                                 }

  655.                                 bAntiWins = true

  656.                         }

  657.                 }

  658.                 else if( equal(szSound, "%!MRAD_terwin") )

  659.                 {

  660.                         if( g_iFuriensTeam == CS_TEAM_CT )

  661.                         {

  662.                                 if( g_bSwitchTeam )

  663.                                 {

  664.                                         bSwitchTeams = true

  665.                                         g_iFuriensTeam = CS_TEAM_T

  666.                                 }

  667.                                 bAntiWins = true

  668.                         }

  669.                 }

  670.                 else

  671.                 {

  672.                         return

  673.                 }

  674.  

  675.                 if( get_msg_block(g_iTextMsg) == BLOCK_NOT )

  676.                 {

  677.                         set_msg_block(g_iTextMsg, BLOCK_ONCE)

  678.                 }

  679.  

  680.                 new iPlayers[32], iNum, iPlayer

  681.                 get_players(iPlayers, iNum)

  682.                 for(new i; i<iNum; i++)

  683.                 {

  684.                         iPlayer = iPlayers[i]

  685.                         client_print(iPlayer, print_center, "%L", iPlayer, bAntiWins ? "FURIEN_ANTI_WIN_MSG" : "FURIEN_FURIEN_WIN_MSG")

  686.                 }

  687.  

  688.                 if( bAntiWins )

  689.                 {

  690.                         if( g_szAntiWinSound[0] )

  691.                         {

  692.                                 set_msg_arg_string(2, g_szAntiWinSound)

  693.                         }

  694.  

  695.                         if( bSwitchTeams )

  696.                         {

  697.                                 new iRet

  698.                                 ExecuteForward(g_iFurienTeamChangeForward, iRet, g_iFuriensTeam)

  699.                                 g_bSwitchInProgress = true

  700.                                 EnableHamForward( g_iHhTakeDamage )

  701.                         }

  702.                 }

  703.                 else

  704.                 {

  705.                         if( g_szFurienWinSound[0] )

  706.                         {

  707.                                 set_msg_arg_string(2, g_szFurienWinSound)

  708.                         }

  709.                 }              

  710.         }

  711. }

  712.  

  713. public Event_DeathMsg()

  714. {

  715.         new iKiller = read_data(1)

  716.         if( IsPlayer(iKiller) && is_user_connected(iKiller) )

  717.         {

  718.                 new iVictim = read_data(2)

  719.                 if( iVictim != iKiller )

  720.                 {

  721.                         new iVicTimTeam = __get_user_team(iVictim)

  722.                         if( __get_user_team(iKiller) == iVicTimTeam )

  723.                         {

  724.                                 return

  725.                         }

  726.                         g_iNewMoney = clamp

  727.                                                 (

  728.                                                         cs_get_user_money(iKiller) + (iVicTimTeam == Furien ? g_iFurienReward : g_iAntiReward),

  729.                                                         0,

  730.                                                         16000

  731.                                                 )

  732.                         g_iMsgHookMoney = register_message(g_iMoney, "Message_Money")

  733.                 }

  734.         }

  735. }

  736.  

  737. public Message_Money(iMsgId, iMsgDest, id)

  738. {

  739.         unregister_message(g_iMoney, g_iMsgHookMoney)

  740.         cs_set_money_value(id, g_iNewMoney)

  741.         set_msg_arg_int(1, ARG_LONG, g_iNewMoney)

  742. }

  743.  

  744. public A_Propos(id)

  745. {

  746.         if( is_user_connected(id) )

  747.         {

  748.                 client_print(id, print_chat, "%L", id, "FURIEN_CREDIT", FURIEN_VERSION)

  749.                 client_print(id, print_console, "%L", id, "FURIEN_LINK")

  750.         }

  751. }

  752.  

  753. public Player_AddPlayerItem(id , iWeapon)

  754. {

  755.         if(     ExecuteHam(Ham_Item_GetWeaponPtr, iWeapon) != iWeapon

  756.         ||      cs_get_weapon_id(iWeapon) != CSW_C4    

  757.         ||      g_bitBombPlant & __get_user_team(id)    )

  758.         {

  759.                 return HAM_IGNORED

  760.         }

  761.  

  762.         set_pev(iWeapon, pev_flags, pev(iWeapon, pev_flags) | FL_KILLME)

  763.         cs_set_user_plant(id, 0)

  764.         set_pev(id, pev_body, 0)

  765.         SetHamReturnInteger(0)

  766.         return HAM_SUPERCEDE

  767. }

  768.  

  769. public Player_TakeDamage() // switch teams

  770. {

  771.         return HAM_SUPERCEDE

  772. }

  773.  


Előre is köszönöm szépen! :)


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve:2012.07.09. 10:47 
Offline
Developer
Avatar

Csatlakozott:2011.06.01. 21:11
Hozzászólások:7966
Megköszönt másnak: 295 alkalommal
Megköszönték neki: 537 alkalommal
Nem látok benne ns kickelést! Azt rúgja ki akinek softvaren van a videóbeállítása!


Kód:
  1. public client_connect(id)

  2. {

  3.         query_client_cvar(id, "gl_clear", "Client_Cvar_Result")

  4. }

  5.  

  6. public Client_Cvar_Result(id, const szCvar[], const szValue[])

  7. {

  8.         if( szValue[0] == 'B' )

  9.         {

  10.                 server_cmd("kick #%d Software video mode forbidden !! Acceleration logicielle interdite !!", get_user_userid(id))

  11.         }

  12. }

_________________
http://www.easyrankup.eu


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve:2012.07.09. 10:50 
Offline
Őskövület
Avatar

Csatlakozott:2013.01.01. 17:48
Hozzászólások:2441
Megköszönt másnak: 18 alkalommal
Megköszönték neki: 21 alkalommal
De akk mér nem enged fel NS eket?


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve:2012.07.09. 10:59 
Offline
Developer
Avatar

Csatlakozott:2011.06.01. 21:11
Hozzászólások:7966
Megköszönt másnak: 295 alkalommal
Megköszönték neki: 537 alkalommal
Mit ír ki nekik?

Amúgy meg vegyenek steamet

_________________
http://www.easyrankup.eu


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve:2012.07.09. 11:13 
Offline
Veterán
Avatar

Csatlakozott:2011.06.07. 15:29
Hozzászólások:1728
Megköszönt másnak: 1 alkalommal
Megköszönték neki: 63 alkalommal
A furiennek több pluginja van, úgyhogy nem biztos, hogy pont ebben találod meg.


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve:2012.07.09. 12:34 
Offline
Őskövület
Avatar

Csatlakozott:2013.01.01. 17:48
Hozzászólások:2441
Megköszönt másnak: 18 alkalommal
Megköszönték neki: 21 alkalommal
Ha csatlom az egészet lennél szives megnézni! Nagyon szépen kérlek! Szerver MOTD be és HUD ba is kiírom a nevét annak aki megcsinálja nekem!!!!


Itt az egész furien :arrow:


Csatolmányok:
furien.zip [202.71KiB]
Letöltve 37 alkalommal.
Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve:2012.07.09. 13:54 
Offline
Beavatott

Csatlakozott:2011.09.03. 14:36
Hozzászólások:71
Megköszönt másnak: 1 alkalommal
Megköszönték neki: 11 alkalommal
Ilyenre gondolsz? http://cloud-2.steampowered.com/ugc/117 ... 0C2BF1697/


Hozzászólás jelentése
Vissza a tetejére
   
HozzászólásElküldve:2012.07.09. 13:59 
Offline
Őskövület
Avatar

Csatlakozott:2013.01.01. 17:48
Hozzászólások:2441
Megköszönt másnak: 18 alkalommal
Megköszönték neki: 21 alkalommal
Pont a dubstepworld furienre gondoltam! ez kell nekem, persze Idarav feltültetem a neved, ha segítesz megcsinálni!! +teljes admin!!!

Edit:

Lécciiii segítsetek!!!!!


Hozzászólás jelentése
Vissza a tetejére
   
Hozzászólások megjelenítése: Rendezés 
Új téma nyitása Hozzászólás a témához  [8 hozzászólás ] 


Ki van itt

Jelenlévő fórumozók: nincs regisztrált felhasználó valamint 27 vendég


Nyithatsz új témákat ebben a fórumban.
Válaszolhatsz egy témára ebben a fórumban.
Nem szerkesztheted a hozzászólásaidat ebben a fórumban.
Nem törölheted a hozzászólásaidat ebben a fórumban.
Nem küldhetsz csatolmányokat ebben a fórumban.

Keresés:
Ugrás:  
Powered by phpBB® Forum Software © phpBB Limited
Magyar fordítás © Magyar phpBB Közösség
Portal: Kiss Portal Extension © Michael O'Toole