hlmod.hu
https://hlmod.hu/

hiba?
https://hlmod.hu/viewtopic.php?f=29&t=13870
Oldal: 1 / 1

Szerző:  metalpatrik [ 2014.01.19. 09:33 ]
Hozzászólás témája:  hiba?

Miért nem engedi át alakitani?
error:
SMA Forráskód: [ Mindet kijelol ]
  1. Welcome to the AMX Mod X 1.8.1-300 Compiler.
  2. Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team
  3. Modified for www.freakz.ro
  4.  
  5. amxmodx_12541-roundbest-1.sma(1) : error 010: invalid function or declaration
  6. amxmodx_12541-roundbest-1.sma(60) : error 017: undefined symbol "NORMAL"
  7. amxmodx_12541-roundbest-1.sma(60) : warning 215: expression has no effect
  8. amxmodx_12541-roundbest-1.sma(60) : warning 215: expression has no effect
  9. amxmodx_12541-roundbest-1.sma(60) : error 001: expected token: ";", but found ")"
  10. amxmodx_12541-roundbest-1.sma(60) : error 029: invalid expression, assumed zero
  11. amxmodx_12541-roundbest-1.sma(60) : fatal error 107: too many error messages on one line
  12.  
  13. Compilation aborted.
  14. 5 Errors.
  15. Done.


plugin:
SMA Forráskód: [ Mindet kijelol ]
  1. #include <amxmodx>
  2. #include <amxmisc>
  3. #include <hamsandwich>
  4. #include <cstrike>
  5. #include <colorchat>
  6.  
  7. #define PLUGIN "New Plugin"
  8. #define AUTHOR "Unknown"
  9. #define VERSION "1.0"
  10.  
  11. new g_iKills[32], g_iHS[32], g_iDmg[32]
  12.  
  13. public plugin_init()
  14. {
  15. register_plugin(PLUGIN, VERSION, AUTHOR)
  16.  
  17. RegisterHam(Ham_TakeDamage, "player", "hamTakeDamage")
  18. register_event("DeathMsg", "EventDeathMsg", "a")
  19. register_logevent("RoundEnd", 2, "1=Round_End")
  20. }
  21. public client_disconnect(id)
  22. {
  23. g_iDmg[id] = 0;
  24. g_iKills[id] = 0;
  25. g_iHS[id] = 0;
  26. }
  27. public hamTakeDamage(victim, inflictor, attacker, Float:damage, DamageBits)
  28. {
  29. if( 1 <= attacker <= 32)
  30. {
  31. if(cs_get_user_team(victim) != cs_get_user_team(attacker))
  32. g_iDmg[attacker] += floatround(damage)
  33. else
  34. g_iDmg[attacker] -= floatround(damage)
  35. }
  36. }
  37. public EventDeathMsg()
  38. {
  39. new killer = read_data(1)
  40. new victim = read_data(2)
  41. new is_hs = read_data(3)
  42.  
  43. if(killer != victim && killer && cs_get_user_team(killer) != cs_get_user_team(victim))
  44. {
  45. g_iKills[killer]++;
  46.  
  47. if(is_hs)
  48. g_iHS[killer]++;
  49. }
  50. else
  51. g_iKills[killer]--;
  52. }
  53. public RoundEnd()
  54. {
  55. new iBestPlayer = get_best_player()
  56.  
  57. new szName[32]
  58. get_user_name(iBestPlayer, szName, charsmax(szName))
  59.  
  60. ColorChat(0, NORMAL, "*^x03 A legjobb játékos ebben a körben,^x04 %s^x03 volt!", szName)
  61. ColorChat(0, NORMAL, "*^x03 Megölt^x04 %i^x03 játékost, ebböl^x04 %i^x03 fejessel!", g_iKills[iBestPlayer], g_iHS[iBestPlayer])
  62.  
  63. for(new i; i < 31; i++)
  64. {
  65. g_iDmg[i] = 0;
  66. g_iHS[i] = 0;
  67. g_iKills[i] = 0;
  68. }
  69. }
  70. get_best_player()
  71. {
  72. new players[32], num;
  73. get_players(players, num);
  74. SortCustom1D(players, num, "sort_bestplayer")
  75.  
  76. return players[0]
  77. }
  78. public sort_bestplayer(id1, id2)
  79. {
  80. if(g_iKills[id1] > g_iKills[id2])
  81. return -1;
  82. else if(g_iKills[id1] < g_iKills[id2])
  83. return 1;
  84. else
  85. {
  86. if(g_iDmg[id1] > g_iDmg[id2])
  87. return -1;
  88. else if(g_iDmg[id1] < g_iDmg[id2])
  89. return 1;
  90. else
  91. return 0;
  92. }
  93.  
  94. return 0;
  95. }

Szerző:  crazy` [ 2014.01.19. 09:35 ]
Hozzászólás témája:  Re: hiba?

Kód:
Welcome to the AMX Mod X 1.76-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Header size:            868 bytes
Code size:             4560 bytes
Data size:             2480 bytes
Stack/heap size:      16384 bytes; max. usage is unknown, due to recursion
Total requirements:   24292 bytes
Done.


colrochattel lesz a baj, nekem átalakítja

Szerző:  metalpatrik [ 2014.01.19. 09:41 ]
Hozzászólás témája:  Re: hiba?

crazy` írta:
Kód:
Welcome to the AMX Mod X 1.76-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Header size:            868 bytes
Code size:             4560 bytes
Data size:             2480 bytes
Stack/heap size:      16384 bytes; max. usage is unknown, due to recursion
Total requirements:   24292 bytes
Done.


colrochattel lesz a baj, nekem átalakítja



Feltudod nekem ide tölteni az amxx et úgy hogy ékezetes a plugin?:S

Szerző:  crazy` [ 2014.01.19. 09:46 ]
Hozzászólás témája:  Re: hiba?

metalpatrik írta:
crazy` írta:
Kód:
Welcome to the AMX Mod X 1.76-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Header size:            868 bytes
Code size:             4560 bytes
Data size:             2480 bytes
Stack/heap size:      16384 bytes; max. usage is unknown, due to recursion
Total requirements:   24292 bytes
Done.


colrochattel lesz a baj, nekem átalakítja



Feltudod nekem ide tölteni az amxx et úgy hogy ékezetes a plugin?:S


nem töltünk fel amxx-et , fordítsd gépen

Szerző:  metalpatrik [ 2014.01.19. 09:47 ]
Hozzászólás témája:  Re: hiba?

Nincs 1 normális foridtó ahova inc-t is fel lehetne tölteni...

Szerző:  lis789 [ 2014.01.19. 10:08 ]
Hozzászólás témája:  Re: hiba?

Töltsd le az amxmodx-et és azon belül alakitsd át!

Oldal: 1 / 1 Minden időpont UTC+02:00 időzóna szerinti
Powered by phpBB® Forum Software © phpBB Limited
https://www.phpbb.com/