Advertisement
scroton

Untitled

Feb 18th, 2015
209
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 19.87 KB | None | 0 0
  1. function int CountPMags(void)
  2. {
  3. int ammo;
  4. ammo = CheckInventory("PMag1");
  5. ammo = ammo + (CheckInventory("PMag2") * 2);
  6. ammo = ammo + (CheckInventory("PMag3") * 3);
  7. ammo = ammo + (CheckInventory("PMag4") * 4);
  8. ammo = ammo + (CheckInventory("PMag5") * 5);
  9. ammo = ammo + (CheckInventory("PMag6") * 6);
  10. ammo = ammo + (CheckInventory("PMag7") * 7);
  11. ammo = ammo + (CheckInventory("PMag8") * 8);
  12. ammo = ammo + (CheckInventory("PMag9") * 9);
  13. ammo = ammo + (CheckInventory("PMag10") * 10);
  14. ammo = ammo + (CheckInventory("PMag11") * 11);
  15. ammo = ammo + (CheckInventory("PMag12") * 12);
  16. ammo = ammo + (CheckInventory("PMag13") * 13);
  17. ammo = ammo + (CheckInventory("PMag14") * 14);
  18. ammo = ammo + (CheckInventory("PMag15") * 15);
  19. return ammo;
  20. }
  21.  
  22. function int GetSmallestPMag(void)
  23. {
  24. int smallestmag;
  25. if(CheckInventory("PMag1")){ smallestmag = 1; }
  26. else if(CheckInventory("PMag2")){ smallestmag = 2; }
  27. else if(CheckInventory("PMag3")){ smallestmag = 3; }
  28. else if(CheckInventory("PMag4")){ smallestmag = 4; }
  29. else if(CheckInventory("PMag5")){ smallestmag = 5; }
  30. else if(CheckInventory("PMag6")){ smallestmag = 6; }
  31. else if(CheckInventory("PMag7")){ smallestmag = 7; }
  32. else if(CheckInventory("PMag8")){ smallestmag = 8; }
  33. else if(CheckInventory("PMag9")){ smallestmag = 9; }
  34. else if(CheckInventory("PMag10")){ smallestmag = 10; }
  35. else if(CheckInventory("PMag11")){ smallestmag = 11; }
  36. else if(CheckInventory("PMag12")){ smallestmag = 12; }
  37. else if(CheckInventory("PMag13")){ smallestmag = 13; }
  38. else if(CheckInventory("PMag14")){ smallestmag = 14; }
  39. else if(CheckInventory("PMag15")){ smallestmag = 15; }
  40. else{ smallestmag = 0; }
  41. return smallestmag;
  42. }
  43.  
  44. function int GetLargestPMag(void)
  45. {
  46. int largestmag;
  47. if(CheckInventory("PMag15")){ largestmag = 15; }
  48. else if(CheckInventory("PMag14")){ largestmag = 14; }
  49. else if(CheckInventory("PMag13")){ largestmag = 13; }
  50. else if(CheckInventory("PMag12")){ largestmag = 12; }
  51. else if(CheckInventory("PMag11")){ largestmag = 11; }
  52. else if(CheckInventory("PMag10")){ largestmag = 10; }
  53. else if(CheckInventory("PMag9")){ largestmag = 9; }
  54. else if(CheckInventory("PMag8")){ largestmag = 8; }
  55. else if(CheckInventory("PMag7")){ largestmag = 7; }
  56. else if(CheckInventory("PMag6")){ largestmag = 6; }
  57. else if(CheckInventory("PMag5")){ largestmag = 5; }
  58. else if(CheckInventory("PMag4")){ largestmag = 4; }
  59. else if(CheckInventory("PMag3")){ largestmag = 3; }
  60. else if(CheckInventory("PMag2")){ largestmag = 2; }
  61. else if(CheckInventory("PMag1")){ largestmag = 1; }
  62. else{ largestmag = 0; }
  63. return largestmag;
  64. }
  65.  
  66. function int GivePMag(int which, int msg, int give)
  67. {
  68. if(give){ GiveInventory("TSPPistolAmmoMag",1); }
  69. switch(which){
  70. case 1:
  71. GiveInventory("PMag1",1);
  72. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+1 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  73. break;
  74. case 2:
  75. GiveInventory("PMag2",1);
  76. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+2 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  77. break;
  78. case 3:
  79. GiveInventory("PMag3",1);
  80. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+3 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  81. break;
  82. case 4:
  83. GiveInventory("PMag4",1);
  84. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+4 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  85. break;
  86. case 5:
  87. GiveInventory("PMag5",1);
  88. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+5 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  89. break;
  90. case 6:
  91. GiveInventory("PMag6",1);
  92. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+6 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  93. break;
  94. case 7:
  95. GiveInventory("PMag7",1);
  96. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+7 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  97. break;
  98. case 8:
  99. GiveInventory("PMag8",1);
  100. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+8 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  101. break;
  102. case 9:
  103. GiveInventory("PMag9",1);
  104. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+9 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  105. break;
  106. case 10:
  107. GiveInventory("PMag10",1);
  108. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+10 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  109. break;
  110. case 11:
  111. GiveInventory("PMag11",1);
  112. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+11 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  113. break;
  114. case 12:
  115. GiveInventory("PMag12",1);
  116. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+12 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  117. break;
  118. case 13:
  119. GiveInventory("PMag13",1);
  120. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+13 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  121. break;
  122. case 14:
  123. GiveInventory("PMag14",1);
  124. if(msg){ hudmessage(s:"Picked up a used pistol magazine. [\cj+14 Pistol Ammo\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  125. break;
  126. case 15:
  127. GiveInventory("PMag15",1);
  128. if(msg){ hudmessage(s:"Picked up a pistol magazine. [\cj+1 Pistol Magazine\c-]";HUDMSG_PLAIN|HUDMSG_LOG,2,CR_RED,0.0,0.0,1.0); }
  129. break; }
  130. return 0;
  131. }
  132.  
  133. function int TakePMag(int which, int throw, int take)
  134. {
  135. if(take){ TakeInventory("TSPPistolAmmoMag",1); }
  136. switch(which){
  137. case 0:
  138. if(throw){ GiveInventory("BaseThrowPMag",1); }
  139. break;
  140. case 1:
  141. TakeInventory("PMag1",1);
  142. if(throw){ GiveInventory("ThrowPMag1",1); }
  143. break;
  144. case 2:
  145. TakeInventory("PMag2",1);
  146. if(throw){ GiveInventory("ThrowPMag2",1); }
  147. break;
  148. case 3:
  149. TakeInventory("PMag3",1);
  150. if(throw){ GiveInventory("ThrowPMag3",1); }
  151. break;
  152. case 4:
  153. TakeInventory("PMag4",1);
  154. if(throw){ GiveInventory("ThrowPMag4",1); }
  155. break;
  156. case 5:
  157. TakeInventory("PMag5",1);
  158. if(throw){ GiveInventory("ThrowPMag5",1); }
  159. break;
  160. case 6:
  161. TakeInventory("PMag6",1);
  162. if(throw){ GiveInventory("ThrowPMag6",1); }
  163. break;
  164. case 7:
  165. TakeInventory("PMag7",1);
  166. if(throw){ GiveInventory("ThrowPMag7",1); }
  167. break;
  168. case 8:
  169. TakeInventory("PMag8",1);
  170. if(throw){ GiveInventory("ThrowPMag8",1); }
  171. break;
  172. case 9:
  173. TakeInventory("PMag9",1);
  174. if(throw){ GiveInventory("ThrowPMag9",1); }
  175. break;
  176. case 10:
  177. TakeInventory("PMag10",1);
  178. if(throw){ GiveInventory("ThrowPMag10",1); }
  179. break;
  180. case 11:
  181. TakeInventory("PMag11",1);
  182. if(throw){ GiveInventory("ThrowPMag11",1); }
  183. break;
  184. case 12:
  185. TakeInventory("PMag12",1);
  186. if(throw){ GiveInventory("ThrowPMag12",1); }
  187. break;
  188. case 13:
  189. TakeInventory("PMag13",1);
  190. if(throw){ GiveInventory("ThrowPMag13",1); }
  191. break;
  192. case 14:
  193. TakeInventory("PMag14",1);
  194. if(throw){ GiveInventory("ThrowPMag14",1); }
  195. break;
  196. case 15:
  197. TakeInventory("PMag15",1);
  198. if(throw){ GiveInventory("ThrowPMag15",1); }
  199. break; }
  200. return 0;
  201. }
  202.  
  203. function int ClearPMags(int take)
  204. {
  205. if(take){ TakeInventory("TSPPistolAmmoMag",0x7FFFFFFF); }
  206. TakeInventory("PMag1",0x7FFFFFFF);
  207. TakeInventory("PMag2",0x7FFFFFFF);
  208. TakeInventory("PMag3",0x7FFFFFFF);
  209. TakeInventory("PMag4",0x7FFFFFFF);
  210. TakeInventory("PMag5",0x7FFFFFFF);
  211. TakeInventory("PMag6",0x7FFFFFFF);
  212. TakeInventory("PMag7",0x7FFFFFFF);
  213. TakeInventory("PMag8",0x7FFFFFFF);
  214. TakeInventory("PMag9",0x7FFFFFFF);
  215. TakeInventory("PMag10",0x7FFFFFFF);
  216. TakeInventory("PMag11",0x7FFFFFFF);
  217. TakeInventory("PMag12",0x7FFFFFFF);
  218. TakeInventory("PMag13",0x7FFFFFFF);
  219. TakeInventory("PMag14",0x7FFFFFFF);
  220. TakeInventory("PMag15",0x7FFFFFFF);
  221. return 0;
  222. }
  223.  
  224. script "PMagChange" ENTER
  225. {
  226. int ammo, maxammo, maxmags;
  227. int lastusemags = GetCVar("tsp_usemags");
  228. Delay(3);
  229. while(true){
  230. if((GetCVar("tsp_usemags") != lastusemags) && !(GetCVar("tsp_usemags"))){
  231. lastusemags = GetCVar("tsp_usemags");
  232. ammo = CountPMags();
  233. ClearPMags(1);
  234. GiveInventory("TSPPistolAmmo",ammo); }
  235. else if((GetCVar("tsp_usemags") != lastusemags) && (GetCVar("tsp_usemags"))){
  236. lastusemags = GetCVar("tsp_usemags");
  237. if(CheckInventory("Backpack2") > 0){ maxmags = 15; }
  238. else{ maxmags = 10; }
  239. ammo = CheckInventory("TSPPistolAmmo");
  240. TakeInventory("TSPPistolAmmo",0x7FFFFFFF);
  241. if((ammo / maxmags) >= 15){
  242. GiveInventory("TSPPistolAmmoMag",maxmags);
  243. GiveInventory("PMag15",maxmags); }
  244. else{
  245. while(ammo > 15){
  246. ammo = ammo - 15;
  247. GiveInventory("TSPPistolAmmoMag",1);
  248. GiveInventory("PMag15",1); }
  249. if(ammo > 0){ GivePMag(ammo,0,1); }}}
  250. Delay(6); }
  251. }
  252.  
  253.  
  254.  
  255.  
  256. script "PMagSpawn" (int chance, int LSchance)
  257. {
  258. int SpawnX, SpawnY, SpawnZ, SpawnAngle;
  259. int roll;
  260. roll = random(1,255);
  261. if((GameSkill() < 5 && roll <= chance) || (GameSkill() >= 5 && roll <= LSchance)){
  262. SpawnX = GetActorX(0);
  263. SpawnY = GetActorY(0);
  264. SpawnZ = GetActorZ(0);
  265. SpawnAngle = GetActorAngle(0);
  266. SpawnForced("PistolAmmoDropper",SpawnX,SpawnY,SpawnZ,0,SpawnAngle); }
  267. }
  268.  
  269. script "PistolMagPickup" (int howmany)
  270. {
  271. int ammo, maxammo, mags, maxmags, smallestmag;
  272. if(GetCVar("tsp_fullmags")){ howmany = 15; }
  273. if(!GetCVar("tsp_usemags") && GameSkill() < 5){
  274. if(CheckInventory("Backpack2") > 0){ maxammo = 300; }
  275. else{ maxammo = 150; }
  276. ammo = CheckInventory("TSPPistolAmmo");
  277. if(ammo < maxammo){
  278. if(howmany == 16){ GiveInventory("TSPPistolAmmo",10); }
  279. else{ GiveInventory("TSPPistolAmmo",5); }
  280. setresultvalue(1);
  281. terminate; }
  282. else{
  283. setresultvalue(0);
  284. terminate; }}
  285. else{
  286. if(CheckInventory("Backpack2") > 0){ maxmags = 15; }
  287. else{ maxmags = 10; }
  288. mags = CheckInventory("TSPPistolAmmoMag");
  289. if(howmany == 16){ howmany = 15; }
  290. if(mags < maxmags){
  291. GivePMag(howmany,1,1);
  292. setresultvalue(1);
  293. terminate; }
  294. else{
  295. smallestmag = GetSmallestPMag();
  296. if(howmany > smallestmag){
  297. GivePMag(howmany,1,0);
  298. TakePMag(smallestmag,1,0);
  299. setresultvalue(1);
  300. terminate; }
  301. else{
  302. setresultvalue(0);
  303. terminate; }}}
  304. }
  305.  
  306. script "PistolReloadCheck" (int which)
  307. {
  308. if(!which){
  309. if(!GetCVar("tsp_usemags") && GameSkill() < 5 && CheckInventory("TSPPistolAmmo")){ setresultvalue(1); }
  310. else if(CheckInventory("TSPPistolAmmoMag")){ setresultvalue(1); }
  311. else{ setresultvalue(0); }}
  312. else{
  313. if((!GetCVar("tsp_usemags") && GameSkill() < 5) &&
  314. (!CheckInventory("TSPPistolAmmo") || CheckInventory("AutoPistolMag") == 15)){
  315. setresultvalue(1); }
  316. else if( CheckInventory("AutoPistolMag") >= GetLargestPMag() || !CheckInventory("TSPPistolAmmoMag")){
  317. setresultvalue(1); }
  318. else{ setresultvalue(0); }}
  319. }
  320.  
  321. script "PMagOut" (void)
  322. {
  323. int mags, maxmags, smallestmag;
  324. int loadedammo;
  325. loadedammo = CheckInventory("AutoPistolMag");
  326. TakeInventory("AutoPistolMag",0x7FFFFFFF);
  327. if(!GetCVar("tsp_usemags") && GameSkill() < 5){
  328. GiveInventory("TSPPistolAmmo",loadedammo);
  329. TakePMag(0,1,0);
  330. terminate; }
  331. else{
  332. if(!loadedammo){
  333. TakePMag(0,1,0);
  334. terminate; }
  335. else{
  336. if(CheckInventory("Backpack2") > 0){ maxmags = 15; }
  337. else{ maxmags = 10; }
  338. mags = CheckInventory("TSPPistolAmmoMag");
  339. if(mags < maxmags){
  340. GivePMag(loadedammo,0,1);
  341. terminate; }
  342. else{
  343. smallestmag = GetSmallestPMag();
  344. if(loadedammo > smallestmag){
  345. TakePMag(smallestmag,1,0);
  346. GivePMag(loadedammo,0,0);
  347. terminate; }
  348. else{
  349. SetUserVariable(0,"user_PMagInGun",loadedammo);
  350. terminate; }}}}
  351. }
  352.  
  353. script "PMagIn" (void)
  354. {
  355. int mags, maxmags, smallestmag, largestmag;
  356. int ammobuffer;
  357. ammobuffer = GetUserVariable(0,"user_PMagInGun");
  358. SetUserVariable(0,"user_PMagInGun",0);
  359. if(!GetCVar("tsp_usemags") && GameSkill() < 5){
  360. while(CheckInventory("AutoPistolMag") < 15){
  361. TakeInventory("TSPPistolAmmo",1);
  362. GiveInventory("AutoPistolMag",1); }}
  363. else{
  364. if(CheckInventory("Backpack2") > 0){ maxmags = 15; }
  365. else{ maxmags = 10; }
  366. largestmag = GetLargestPMag();
  367. TakePMag(largestmag,0,1);
  368. GiveInventory("AutoPistolMag",largestmag);
  369. if(ammobuffer){
  370. GivePMag(ammobuffer,0,1); }}
  371. }
  372.  
  373.  
  374. Actor PMag15 : Boolean { Inventory.MaxAmount 15 }
  375. Actor PMag14 : PMag15 {}
  376. Actor PMag13 : PMag15 {}
  377. Actor PMag12 : PMag15 {}
  378. Actor PMag11 : PMag15 {}
  379. Actor PMag10 : PMag15 {}
  380. Actor PMag9 : PMag15 {}
  381. Actor PMag8 : PMag15 {}
  382. Actor PMag7 : PMag15 {}
  383. Actor PMag6 : PMag15 {}
  384. Actor PMag5 : PMag15 {}
  385. Actor PMag4 : PMag15 {}
  386. Actor PMag3 : PMag15 {}
  387. Actor PMag2 : PMag15 {}
  388. Actor PMag1 : PMag15 {}
  389.  
  390. ACTOR TSPPistolAmmoDrop replaces Clip
  391. {
  392. States
  393. {
  394. Spawn:
  395. TNT1 A 0
  396. TNT1 A 0
  397. TNT1 A 0
  398. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("TSPGetGameSkill") == 5,"LoneSurvivorSpawn")
  399. Goto SpawnAmmo
  400. LoneSurvivorSpawn:
  401. TNT1 A 0 A_Jump(155,"SpawnAmmo")
  402. Stop
  403. SpawnAmmo:
  404. TNT1 A 0 A_SpawnItemEx("BasePistolMag",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION)
  405. Stop
  406. }
  407. }
  408.  
  409. ACTOR PistolAmmoDropper
  410. {
  411. Height 2
  412. Radius 2
  413. +NOINTERACTION
  414. +NOCLIP
  415. +THRUACTORS
  416. States
  417. {
  418. Spawn:
  419. TNT1 A 0
  420. TNT1 A 0
  421. TNT1 A 0
  422. TNT1 A 0
  423. TNT1 A 0 A_Jump(256,"Drop5","Drop6","Drop7","Drop8","Drop9","Drop10","Drop11","Drop12","Drop13","Drop14","Drop15")
  424. Wait
  425. Drop5:
  426. TNT1 A 0 A_DropItem("PistolMag5")
  427. Stop
  428. Drop6:
  429. TNT1 A 0 A_DropItem("PistolMag6")
  430. Stop
  431. Drop7:
  432. TNT1 A 0 A_DropItem("PistolMag7")
  433. Stop
  434. Drop8:
  435. TNT1 A 0 A_DropItem("PistolMag8")
  436. Stop
  437. Drop9:
  438. TNT1 A 0 A_DropItem("PistolMag9")
  439. Stop
  440. Drop10:
  441. TNT1 A 0 A_DropItem("PistolMag10")
  442. Stop
  443. Drop11:
  444. TNT1 A 0 A_DropItem("PistolMag11")
  445. Stop
  446. Drop12:
  447. TNT1 A 0 A_DropItem("PistolMag12")
  448. Stop
  449. Drop13:
  450. TNT1 A 0 A_DropItem("PistolMag13")
  451. Stop
  452. Drop14:
  453. TNT1 A 0 A_DropItem("PistolMag14")
  454. Stop
  455. Drop15:
  456. TNT1 A 0 A_DropItem("PistolMag15")
  457. Stop
  458. }
  459. }
  460.  
  461. ACTOR BasePistolMag : CustomInventory
  462. {
  463. Inventory.PickupMessage ""
  464. Inventory.PickupSound "919m/magout"
  465. DeathSound "weapons/smallclip"
  466. +INVENTORY.AUTOACTIVATE
  467. +CORPSE
  468. States
  469. {
  470. Spawn:
  471. 919F ABCDEFGH 2
  472. Loop
  473. Crash:
  474. TNT1 A 0 A_Jump(85,"Crash1","Crash2","Crash3","Crash4")
  475. Wait
  476. Crash1:
  477. 919F A -1 A_Scream
  478. Stop
  479. Crash2:
  480. 919F C -1 A_Scream
  481. Stop
  482. Crash3:
  483. 919F G -1 A_Scream
  484. Stop
  485. Crash4:
  486. 919F E -1 A_Scream
  487. Stop
  488. Pickup:
  489. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",16),"PickupSuccess")
  490. Fail
  491. PickupSuccess:
  492. TNT1 A 0 A_RailWait
  493. Stop
  494. }
  495. }
  496.  
  497. ACTOR PistolMag1 : BasePistolMag
  498. {
  499. States
  500. {
  501. Pickup:
  502. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",1),"PickupSuccess")
  503. Fail
  504. }
  505. }
  506.  
  507. ACTOR PistolMag2 : BasePistolMag
  508. {
  509. States
  510. {
  511. Pickup:
  512. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",2),"PickupSuccess")
  513. Fail
  514. }
  515. }
  516.  
  517. ACTOR PistolMag3 : BasePistolMag
  518. {
  519. States
  520. {
  521. Pickup:
  522. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",3),"PickupSuccess")
  523. Fail
  524. }
  525. }
  526.  
  527. ACTOR PistolMag4 : BasePistolMag
  528. {
  529. States
  530. {
  531. Pickup:
  532. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",4),"PickupSuccess")
  533. Fail
  534. }
  535. }
  536.  
  537. ACTOR PistolMag5 : BasePistolMag
  538. {
  539. States
  540. {
  541. Pickup:
  542. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",5),"PickupSuccess")
  543. Fail
  544. }
  545. }
  546.  
  547. ACTOR PistolMag6 : BasePistolMag
  548. {
  549. States
  550. {
  551. Pickup:
  552. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",6),"PickupSuccess")
  553. Fail
  554. }
  555. }
  556.  
  557. ACTOR PistolMag7 : BasePistolMag
  558. {
  559. States
  560. {
  561. Pickup:
  562. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",7),"PickupSuccess")
  563. Fail
  564. }
  565. }
  566.  
  567. ACTOR PistolMag8 : BasePistolMag
  568. {
  569. States
  570. {
  571. Pickup:
  572. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",8),"PickupSuccess")
  573. Fail
  574. }
  575. }
  576.  
  577. ACTOR PistolMag9 : BasePistolMag
  578. {
  579. States
  580. {
  581. Pickup:
  582. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",9),"PickupSuccess")
  583. Fail
  584. }
  585. }
  586.  
  587. ACTOR PistolMag10 : BasePistolMag
  588. {
  589. States
  590. {
  591. Pickup:
  592. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",10),"PickupSuccess")
  593. Fail
  594. }
  595. }
  596.  
  597. ACTOR PistolMag11 : BasePistolMag
  598. {
  599. States
  600. {
  601. Pickup:
  602. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",11),"PickupSuccess")
  603. Fail
  604. }
  605. }
  606.  
  607. ACTOR PistolMag12 : BasePistolMag
  608. {
  609. States
  610. {
  611. Pickup:
  612. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",12),"PickupSuccess")
  613. Fail
  614. }
  615. }
  616.  
  617. ACTOR PistolMag13 : BasePistolMag
  618. {
  619. States
  620. {
  621. Pickup:
  622. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",13),"PickupSuccess")
  623. Fail
  624. }
  625. }
  626.  
  627. ACTOR PistolMag14 : BasePistolMag
  628. {
  629. States
  630. {
  631. Pickup:
  632. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",14),"PickupSuccess")
  633. Fail
  634. }
  635. }
  636.  
  637. ACTOR PistolMag15 : BasePistolMag
  638. {
  639. States
  640. {
  641. Pickup:
  642. TNT1 A 0 A_JumpIf(ACS_NamedExecuteWithResult("PistolMagPickup",15),"PickupSuccess")
  643. Fail
  644. }
  645. }
  646.  
  647. Actor BaseThrowPMag : CustomInventory
  648. {
  649. +INVENTORY.AUTOACTIVATE
  650. Inventory.Amount 1
  651. Inventory.MaxAmount 1
  652. States
  653. {
  654. Pickup:
  655. TNT1 A 0 A_FireCustomMissile("SpentClip1",3,0,-4,-12)
  656. Stop
  657. }
  658. }
  659.  
  660. Actor ThrowPMag1 : BaseThrowPMag
  661. {
  662. States
  663. {
  664. Pickup:
  665. TNT1 A 0 A_FireCustomMissile("PistolMag1",3,0,-4,-12)
  666. Stop
  667. }
  668. }
  669.  
  670. Actor ThrowPMag2 : BaseThrowPMag
  671. {
  672. States
  673. {
  674. Pickup:
  675. TNT1 A 0 A_FireCustomMissile("PistolMag2",3,0,-4,-12)
  676. Stop
  677. }
  678. }
  679.  
  680. Actor ThrowPMag3 : BaseThrowPMag
  681. {
  682. States
  683. {
  684. Pickup:
  685. TNT1 A 0 A_FireCustomMissile("PistolMag3",3,0,-4,-12)
  686. Stop
  687. }
  688. }
  689.  
  690. Actor ThrowPMag4 : BaseThrowPMag
  691. {
  692. States
  693. {
  694. Pickup:
  695. TNT1 A 0 A_FireCustomMissile("PistolMag4",3,0,-4,-12)
  696. Stop
  697. }
  698. }
  699.  
  700. Actor ThrowPMag5 : BaseThrowPMag
  701. {
  702. States
  703. {
  704. Pickup:
  705. TNT1 A 0 A_FireCustomMissile("PistolMag5",3,0,-4,-12)
  706. Stop
  707. }
  708. }
  709.  
  710. Actor ThrowPMag6 : BaseThrowPMag
  711. {
  712. States
  713. {
  714. Pickup:
  715. TNT1 A 0 A_FireCustomMissile("PistolMag6",3,0,-4,-12)
  716. Stop
  717. }
  718. }
  719.  
  720. Actor ThrowPMag7 : BaseThrowPMag
  721. {
  722. States
  723. {
  724. Pickup:
  725. TNT1 A 0 A_FireCustomMissile("PistolMag7",3,0,-4,-12)
  726. Stop
  727. }
  728. }
  729.  
  730. Actor ThrowPMag8 : BaseThrowPMag
  731. {
  732. States
  733. {
  734. Pickup:
  735. TNT1 A 0 A_FireCustomMissile("PistolMag8",3,0,-4,-12)
  736. Stop
  737. }
  738. }
  739.  
  740. Actor ThrowPMag9 : BaseThrowPMag
  741. {
  742. States
  743. {
  744. Pickup:
  745. TNT1 A 0 A_FireCustomMissile("PistolMag9",3,0,-4,-12)
  746. Stop
  747. }
  748. }
  749.  
  750. Actor ThrowPMag10 : BaseThrowPMag
  751. {
  752. States
  753. {
  754. Pickup:
  755. TNT1 A 0 A_FireCustomMissile("PistolMag10",3,0,-4,-12)
  756. Stop
  757. }
  758. }
  759.  
  760. Actor ThrowPMag11 : BaseThrowPMag
  761. {
  762. States
  763. {
  764. Pickup:
  765. TNT1 A 0 A_FireCustomMissile("PistolMag11",3,0,-4,-12)
  766. Stop
  767. }
  768. }
  769.  
  770. Actor ThrowPMag12 : BaseThrowPMag
  771. {
  772. States
  773. {
  774. Pickup:
  775. TNT1 A 0 A_FireCustomMissile("PistolMag12",3,0,-4,-12)
  776. Stop
  777. }
  778. }
  779.  
  780. Actor ThrowPMag13 : BaseThrowPMag
  781. {
  782. States
  783. {
  784. Pickup:
  785. TNT1 A 0 A_FireCustomMissile("PistolMag13",3,0,-4,-12)
  786. Stop
  787. }
  788. }
  789.  
  790. Actor ThrowPMag14 : BaseThrowPMag
  791. {
  792. States
  793. {
  794. Pickup:
  795. TNT1 A 0 A_FireCustomMissile("PistolMag14",3,0,-4,-12)
  796. Stop
  797. }
  798. }
  799.  
  800. Actor ThrowPMag15 : BaseThrowPMag
  801. {
  802. States
  803. {
  804. Pickup:
  805. TNT1 A 0 A_FireCustomMissile("PistolMag15",3,0,-4,-12)
  806. Stop
  807. }
  808. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement