hlmod.hu
https://hlmod.hu/

[ZP] Fertőzés Visszaszámoló
https://hlmod.hu/viewtopic.php?f=9&t=9490
Oldal: 1 / 1

Szerző:  norbee.16 [ 2013.07.15. 07:20 ]
Hozzászólás témája:  [ZP] Fertőzés Visszaszámoló

Hali!
Az lene a bajom hogy például már az 8-t írja de még csak a 9-t mondja szóval az írás siet :D
SMA Forráskód: [ Mindet kijelol ]
  1.  
  2. #include <amxmodx>
  3.  
  4. #include <amxmisc>
  5.  
  6. #include <zombieplague>
  7.  
  8.  
  9.  
  10. #define PLUGIN "[ZP] Szamok"
  11.  
  12. #define VERSION "1.0"
  13.  
  14. #define AUTHOR "Mr.Apple"
  15.  
  16.  
  17.  
  18. new const speak[ 10 ][] = {
  19.  
  20. "ebasound56/one.wav",
  21.  
  22. "ebasound56/two.wav",
  23.  
  24. "ebasound56/three.wav",
  25.  
  26. "ebasound56/four.wav",
  27.  
  28. "ebasound56/five.wav",
  29.  
  30. "ebasound56/six.wav",
  31.  
  32. "ebasound56/seven.wav",
  33.  
  34. "ebasound56/eight.wav",
  35.  
  36. "ebasound56/nine.wav",
  37.  
  38. "ebasound56/ten.wav"
  39.  
  40. }
  41.  
  42.  
  43.  
  44. new countdown
  45.  
  46.  
  47.  
  48. public plugin_init() {
  49.  
  50. register_plugin(PLUGIN, VERSION, AUTHOR)
  51.  
  52. register_event("HLTV", "event_round_start", "a", "1=0", "2=0")
  53.  
  54. }
  55.  
  56.  
  57.  
  58. public plugin_precache() {
  59.  
  60. precache_sound( "ebasound56/ten.wav" )
  61.  
  62. precache_sound( "ebasound56/nine.wav" )
  63.  
  64. precache_sound( "ebasound56/eight.wav" )
  65.  
  66. precache_sound( "ebasound56/seven.wav" )
  67.  
  68. precache_sound( "ebasound56/six.wav" )
  69.  
  70. precache_sound( "ebasound56/five.wav" )
  71.  
  72. precache_sound( "ebasound56/four.wav" )
  73.  
  74. precache_sound( "ebasound56/three.wav" )
  75.  
  76. precache_sound( "ebasound56/two.wav" )
  77.  
  78. precache_sound( "ebasound56/one.wav" )
  79.  
  80. }
  81.  
  82.  
  83.  
  84. public event_round_start() {
  85.  
  86. set_task(3.0, "zombie_countdown")
  87.  
  88. countdown = 9
  89.  
  90. }
  91.  
  92.  
  93.  
  94. public zombie_countdown() {
  95.  
  96. emit_sound( 0, CHAN_VOICE, speak[ countdown ], 1.0, ATTN_NORM, 0, PITCH_NORM )
  97.  
  98.  
  99.  
  100. set_hudmessage(179, 0, 0, -1.0, 0.28, 2, 0.02, 1.0, 0.01, 0.1, 10);
  101.  
  102. show_hudmessage(0, "Fertozesig hatra maradt %i masodperc", countdown);
  103.  
  104. countdown--
  105.  
  106.  
  107.  
  108. if(countdown > 0) {
  109.  
  110. set_task(1.0, "zombie_countdown")
  111.  
  112. }
  113.  
  114. }
  115.  
  116.  

Szerző:  Metal [ 2013.07.15. 09:21 ]
Hozzászólás témája:  Re: [ZP] Fertőzés Visszaszámoló

SMA Forráskód: [ Mindet kijelol ]
  1. show_hudmessage(0, "Fertozesig hatra maradt %i masodperc", countdown);


-->

SMA Forráskód: [ Mindet kijelol ]
  1. show_hudmessage(0, "Fertozesig hatra maradt %i masodperc", countdown + 1);

Szerző:  norbee.16 [ 2013.10.24. 21:59 ]
Hozzászólás témája:  Re: [ZP] Fertőzés Visszaszámoló

Metal írta:
SMA Forráskód: [ Mindet kijelol ]
  1. show_hudmessage(0, "Fertozesig hatra maradt %i masodperc", countdown);


-->

SMA Forráskód: [ Mindet kijelol ]
  1. show_hudmessage(0, "Fertozesig hatra maradt %i masodperc", countdown + 1);

Már egy aprócska hiba van. Az 1-et nem mondja :S Ezt kéne nekem meg oldani.

Szerző:  ChaspeR [ 2013.10.26. 12:47 ]
Hozzászólás témája:  Re: [ZP] Fertőzés Visszaszámoló

Rakd feljebb a cfgs fájlba akkor szerintem mondja :D

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