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.
|
Guest Message by DevFuse
Wklejka 66fkraemrpwc dodana przez speedkill, 17.05.2012 17:23
1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. 17. 18. 19. 20. 21. 22. 23. 24. 25. 26. 27. 28. 29. 30. 31. 32. 33. 34. 35. 36. 37. 38. 39. 40. 41. 42. 43. 44. 45. 46. 47. 48. 49. 50. 51. 52. 53. 54. 55. 56. 57. 58. 59. 60. 61. 62. 63. 64. 65. 66. 67. 68. 69. 70. 71. 72. 73. 74. 75. 76. 77. 78. 79. 80. 81. 82. 83. 84. 85. 86. 87. 88. 89. 90. 91. 92. 93. 94. 95. 96. 97. 98. 99. 100. 101. 102. 103. 104. 105. 106. 107. 108. 109. 110. 111. 112. 113. 114. 115. 116. 117. 118. 119. 120. 121. 122. 123. 124. 125. 126. 127. 128. 129. 130. 131. 132. 133. 134. 135. 136. 137. 138. 139. 140. 141. 142. 143. 144. 145. 146.
/* Plugin generated by AMXX-Studio */
#include <amxmodx>
#include <amxmisc>
#include <codmod>
#include <hamsandwich>
#include <colorchat>
#include <engine>
#define PLUGIN "Specjal"
#define VERSION "0.1"
#define AUTHOR "BoB0_"
new bool:ma_klase[33];
new bool:special_uzyty[33];
new special[33];
new msg_bartime;
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR);
RegisterHam(Ham_Spawn, "player", "Spawn");
msg_bartime = get_user_msgid("BarTime");
register_clcmd("special", "class_special_used");
}
public Spawn(id)
{
new level = cod_get_user_level(id);
if(!is_user_connected(id))
return HAM_IGNORED;
if(!ma_klase[id])
return HAM_IGNORED;
if(!(level >= 160))
return HAM_IGNORED;
new special = random_num(0, 3)
switch(special)
{
case 0:
{
ColorChat(id, GREEN, "Wylosowales bonusowe zycie.");
}
case 1:
{
ColorChat(id, GREEN, "Wylosowales bonusowa inteligencje.");
}
case 2:
{
ColorChat(id, GREEN, "Wylosowales bonusowa kondycje.");
}
case 3:
{
ColorChat(id, GREEN, "Wylosowales bonusowa wytrzymalosc.");
}
}
}
public class_special_used(id)
{
new level = cod_get_user_level(id);
if(!is_user_connected(id))
return;
if(!ma_klase[id])
return;
if(!(level >= 160))
{
ColorChat(id, GREEN, "Musisz miec level 160 lub wiekszy aby uzywac speciali.");
return;
}
if(special_uzyty[id])
{
ColorChat(id, GREEN, "Special jest juz wlaczony.");
return;
}
if(special[id] == 0)
{
special_uzyty[id] = true;
ColorChat(id, GREEN, "Special on.");
cod_set_user_bonus_health(id, 100);
set_bartime(id, 10);
set_task(10.0, "WylaczSpecial", id);
return;
}
if(special[id] == 1)
{
special_uzyty[id] = true;
ColorChat(id, GREEN, "Special on.");
cod_set_user_bonus_intelligence(id, 100);
set_bartime(id, 10);
set_task(10.0, "WylaczSpecial", id);
return;
}
if(special[id] == 2)
{
special_uzyty[id] = true;
ColorChat(id, GREEN, "Special on.");
cod_set_user_bonus_trim(id, 100);
set_bartime(id, 10);
set_task(10.0, "WylaczSpecial", id);
return;
}
if(special[id] == 3)
{
special_uzyty[id] = true;
ColorChat(id, GREEN, "Special on.");
cod_set_user_bonus_stamina(id, 100);
set_bartime(id, 10);
set_task(10.0, "WylaczSpecial", id);
return;
}
return;
}
public WylaczSpecial(id)
{
special_uzyty[id] = false;
ColorChat(id, GREEN, "Special off");
}
public set_bartime(id, czas)
{
message_begin(MSG_ONE, msg_bartime, _, id);
write_short(czas);
message_end();
}
Dodanych wklejek: 12861
Powered By (Pav32) Pastebin © 2011


Dodatki SourceMod


