Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local function h(v, p)
- local ico_pistol = v.cachePatch("WUSPA0")
- local ico_shotty = v.cachePatch("STPNA0")
- local ico_nailgun = v.cachePatch("PCSPA0")
- for player in players.iterate
- v.drawNum(50, 76, player.heart);
- v.drawNum(300, 30, player.weaponorder);
- if player.weaponorder == 0
- v.drawString(300, 16, "Fist", V_ALLOWLOWERCASE,"right");
- end
- if player.weaponorder == 1
- v.drawNum(300, 172, player.autoammo);
- v.drawNum(250, 172, player.pistolclip);
- v.draw(270, 170, ico_pistol);
- v.drawString(300, 16, "Pistol", V_ALLOWLOWERCASE,"right");
- v.drawString(300, 184, "Auto", V_ALLOWLOWERCASE,"right");
- end
- if player.weaponorder == 2
- v.drawNum(300, 172, player.scatterammo);
- v.drawNum(250, 172, player.shottyclip);
- v.draw(270, 170, ico_shotty);
- v.drawString(300, 16, "Shotgun", V_ALLOWLOWERCASE,"right");
- v.drawString(300, 184, "Scatter", V_ALLOWLOWERCASE,"right");
- end
- if player.weaponorder == 3
- v.drawNum(300, 172, player.autoammo);
- v.drawNum(250, 172, player.nailclip);
- v.draw(270, 170, ico_nailgun);
- v.drawString(300, 16, "Nailgun", V_ALLOWLOWERCASE,"right");
- v.drawString(300, 184, "Auto", V_ALLOWLOWERCASE,"right");
- end
- end
- end
- local animatedelay = 0
- local animatedelaytwo = 0
- local function wep(v, p)
- if animatedelay > 0
- animatedelay = $1-1
- end
- if animatedelaytwo > 0
- animatedelaytwo = $1-1
- end
- if player.fistswung >= 1
- animatedelay = 16
- end
- if player.pistolfired >= 1
- animatedelay = 16
- end
- if player.shottyfired >= 1
- animatedelay = 28
- end
- if player.nailfired >= 1
- animatedelay = 4
- end
- if player.pistolreload >= 1
- animatedelaytwo = 32
- end
- if player.shottyreload >= 1
- animatedelaytwo = 14
- end
- if player.nailreload >= 1
- animatedelaytwo = 46
- end
- if player.weaponorder == 0
- fist_ready = v.cachePatch("PUNGA0")
- fist_swing1 = v.cachePatch("PUNGB0")
- fist_swing2 = v.cachePatch("PUNGC0")
- fist_swing3 = v.cachePatch("PUNGD0")
- if animatedelay == 0
- v.draw(0, 0, fist_ready);
- elseif animatedelay >= 16
- v.draw(0, 0, fist_swing1);
- elseif animatedelay >= 12
- v.draw(0, 0, fist_swing2);
- elseif animatedelay >= 8
- v.draw(0, 0, fist_swing3);
- elseif animatedelay >= 4
- v.draw(0, 0, fist_swing2);
- elseif animatedelay >= 1
- v.draw(0, 0, fist_swing1);
- end
- end
- if player.weaponorder == 1
- pistol_ready = v.cachePatch("WUSSA0")
- pistol_flash = v.cachePatch("WUSFA0")
- pistol_shoot1 = v.cachePatch("WUSSB0")
- pistol_shoot2 = v.cachePatch("WUSSC0")
- pistol_shoot3 = v.cachePatch("WUSSD0")
- pistol_shoot4 = v.cachePatch("WUSSE0")
- pistol_reload1 = v.cachePatch("WUSSF0")
- pistol_reload2 = v.cachePatch("WUSSG0")
- pistol_reload3 = v.cachePatch("WUSSH0")
- pistol_reload4 = v.cachePatch("WUSSI0")
- if animatedelay == 0
- and animatedelaytwo == 0
- v.draw(0, 0, pistol_ready);
- elseif animatedelay >= 16
- v.draw(0, 0, pistol_shoot1);
- v.draw(0, 0, pistol_flash);
- elseif animatedelay >= 14
- v.draw(0, 0, pistol_shoot2);
- elseif animatedelay >= 12
- v.draw(0, 0, pistol_shoot3);
- elseif animatedelay >= 10
- v.draw(0, 0, pistol_shoot4);
- elseif animatedelay >= 8
- v.draw(0, 0, pistol_shoot3);
- elseif animatedelay >= 6
- v.draw(0, 0, pistol_shoot2);
- elseif animatedelay >= 4
- v.draw(0, 0, pistol_shoot1);
- elseif animatedelay >= 1
- v.draw(0, 0, pistol_ready);
- end
- if animatedelaytwo >= 32
- and animatedelay == 0
- v.draw(0, 0, pistol_ready);
- elseif animatedelaytwo >= 31
- v.draw(0, 0, pistol_reload1);
- elseif animatedelaytwo >= 28
- v.draw(0, 0, pistol_reload2);
- elseif animatedelaytwo >= 26
- v.draw(0, 0, pistol_reload3);
- elseif animatedelaytwo >= 24
- v.draw(0, 0, pistol_reload4);
- elseif animatedelaytwo >= 22
- v.draw(0, 0, pistol_reload4);
- elseif animatedelaytwo >= 6
- v.draw(0, 0, pistol_reload3);
- elseif animatedelaytwo >= 4
- v.draw(0, 0, pistol_reload2);
- elseif animatedelaytwo >= 1
- v.draw(0, 0, pistol_ready);
- end
- end
- if player.weaponorder == 2
- shotty_ready = v.cachePatch("STGNA0")
- shotty_reload1 = v.cachePatch("STGNB0")
- shotty_reload2 = v.cachePatch("STGNC0")
- shotty_reload3 = v.cachePatch("STGND0")
- shotty_reload4 = v.cachePatch("STGNE0")
- shotty_reload5 = v.cachePatch("STGNF0")
- shotty_shoot1 = v.cachePatch("STGNG0")
- shotty_shoot2 = v.cachePatch("STGNH0")
- shotty_shoot3 = v.cachePatch("STGNI0")
- shotty_flash = v.cachePatch("STFNA0")
- if animatedelay == 0
- and animatedelaytwo == 0
- v.draw(0, 0, shotty_ready);
- elseif animatedelay >= 28
- v.draw(0, 0, shotty_ready);
- v.draw(0, 0, shotty_flash);
- elseif animatedelay >= 26
- v.draw(0, 0, shotty_shoot1);
- elseif animatedelay >= 22
- v.draw(0, 0, shotty_shoot2);
- elseif animatedelay >= 18
- v.draw(0, 0, shotty_shoot3);
- elseif animatedelay >= 14
- v.draw(0, 0, shotty_shoot2);
- elseif animatedelay >= 12
- v.draw(0, 0, shotty_shoot1);
- end
- end
- if player.weaponorder == 3
- nail_ready = v.cachePatch("PCGNA0")
- nail_fire1 = v.cachePatch("PCGNB0")
- nail_fire2 = v.cachePatch("PCGNC0")
- nail_reload1 = v.cachePatch("PCGND0")
- nail_reload2 = v.cachePatch("PCGNE0")
- nail_flash1 = v.cachePatch("PCGFA0")
- nail_flash2 = v.cachePatch("PCGFB0")
- if animatedelay == 0
- and animatedelaytwo == 0
- v.draw(0, 0, nail_ready);
- elseif animatedelay >= 2
- v.draw(0, 0, nail_fire1);
- v.draw(0, 0, nail_flash1);
- elseif animatedelay >= 1
- v.draw(0, 0, nail_fire2);
- v.draw(0, 0, nail_flash2);
- elseif animatedelaytwo >= 44
- v.draw(0, 0, nail_reload1);
- elseif animatedelaytwo >= 3
- v.draw(0, 0, nail_reload2);
- elseif animatedelaytwo >= 1
- v.draw(0, 0, nail_reload1);
- end
- end
- end
- hud.add(h, "game")
- hud.add(wep, "game")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement