AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Zombie Plague Mod (https://forums.alliedmods.net/forumdisplay.php?f=126)
-   -   Subplugin Submission [ZP 5.0][1.5.0] Sprinting (https://forums.alliedmods.net/showthread.php?t=170792)

Excalibur.007 10-29-2011 00:34

[ZP 5.0][1.5.0] Sprinting
 
2 Attachment(s)
Description
This adds a basic sprinting to human that allows them to run faster for a certain amount of duration.
Plugin was tested on Zombie Plague 5.0.7

Version history:
  • 1.0 - Initial release
  • 1.0.1 - Bug fix - Doesn't set cl_bob back to default if client set realism to disabled when sprinting.
  • 1.5.0 - Almost whole code rewritten
    - Removed fun
    - A lot of optimization
    - Fixed cl_bob not resetting if server changes map.
    - SPEED BUG IS NO MORE!
    - Change speed setting to multiplier
    - Sprint help chat loops every 55.0 seconds by default
    - Uses ZP 5.0 color chat
    - Added more realism(sideways, backwards, ducking & jumping will disable sprinting)

CVars:
Code:

zp_sprint_speed_multiplier "1.5"
zp_sprint_max_duration "7.0"
zp_sprint_min_time_for_sound "5.0"

CVars description:
  • zp_sprint_speed_multiplier - Multiply the current speed you have.
  • zp_sprint_max_duration - Max duration for sprinting
  • zp_sprint_min_time_for_sound - Minimum time in sprinting needed for sound effect

Client commands:
  • Chat: /sprint
    Allow/Disallow sprint realism (editing client CVars /w client's permission through a basic menu)
  • Console: sprint
    Bind this key to sprint e.g.
    Code:

    bind v sprint

Notes:
  • Sprinting can be stopped any time by pressing the binded key again while sprinting.
  • Before sprinting, there's no need to hold the binded key as it doesn't use the + and - commands. One press will allow you to sprint/disable sprint
  • Version 1.5.0 is FULLY tested. So if you have problems with it, disable any plugins that doesn't come with AMXX and Zombie Plague.

F.A.Q:

Code:

Q. Where's the cooldown CVar?
A. I did thought of adding it but if they sprinted for just 1 sec, the cooldown would be non-realistic. Cooldown is based on the time they sprinted. E.g. If Player 1 sprinted for 5.0 seconds, his cooldown would be 5.0 seconds.

Q. Will the sound automatically stop when cooldown is over?
A. Yes. The sound will play until the cooldown is over.

Q. Why use the menu for editing client CVar? Why not just edit it?
A. Slowhacking is not allowed. The menu will allow player to choose whether the plugin is allowed to change their CVar.


jc980 10-30-2011 00:56

Re: [ZP 5.0] Addon: Basic Sprinting 1.0
 
YES!!!! Now I can make a damn NAZI ZOMBIES Game.

Good Job. Thx for plugin! very cool!

Nick Haldem 10-30-2011 04:42

Re: [ZP 5.0] Addon: Basic Sprinting 1.0
 
Its like second run?

JoKeR LauGh 10-30-2011 06:31

Re: [ZP 5.0] Addon: Basic Sprinting 1.0
 
Is this an extra item ? sound's cools . :up::up:

bibu 10-30-2011 06:35

Re: [ZP 5.0] Addon: Basic Sprinting 1.0
 
Excalibur, you know that you're using slowhack right? Remove it so.

Nick Haldem 10-30-2011 06:36

Re: [ZP 5.0] Addon: Basic Sprinting 1.0
 
No.Its addon.All playes can use it free

JoKeR LauGh 10-30-2011 06:54

Re: [ZP 5.0] Addon: Basic Sprinting 1.0
 
PHP Code:

client_cmd(id"cl_bob 0.01"

this is slow-hacking ?

Excalibur.007 10-30-2011 09:02

Re: [ZP 5.0] Addon: Basic Sprinting 1.0
 
Yeah, but it doesn't edit the cvar as long the client didn't press yes on the menu. If it still considered as slowhacking even after client permission through the menu then I'll remove it, will wait for post before updating plugin.

EDIT: Bug fix on 1.0.1. If anybody knows how to block sideway/backwards movement please post here. I need the codes for more realism as the current one allows sideway/backwards movement. Thanks in advance.

jc980 11-02-2011 08:58

Re: [ZP 5.0] Addon: Basic Sprinting 1.0
 
Quote:

Originally Posted by Excalibur.007 (Post 1586393)
Yeah, but it doesn't edit the cvar as long the client didn't press yes on the menu. If it still considered as slowhacking even after client permission through the menu then I'll remove it, will wait for post before updating plugin.

EDIT: Bug fix on 1.0.1. If anybody knows how to block sideway/backwards movement please post here. I need the codes for more realism as the current one allows sideway/backwards movement. Thanks in advance.

shake the screen left then right with punch angle while sprinting?

JoKeR LauGh 11-02-2011 09:05

Re: [ZP 5.0] Addon: Basic Sprinting 1.0.1
 
I just can't really understand this plugin . It just like make you sprint or it just like the other zombie games that give sprint and the sprint will expired when the energy is run out . Is it like that ?


All times are GMT -4. The time now is 15:31.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.