Kreedz Record Demo v0.8.0 (beta) !!

Started by gladius
18/04/2014 02:15
Page 1 of 8
gladius18/04/2014 02:15(edited 19/05/2015 05:42)

Plugin for recording kz demo.

v0.8.0 by gladius


What's the difference with kzdemo by Kr1zo?
- I made this almost from scratch and I improved a lot of the code.
- I added new features and stuff
- I do not remember other things now

Features:
- Godmode
- Noclip
- Checkpoints
- Auto heal 10'000 HP
- Climb time (format 00:00.00)
- Auto join
- Save start position
- Shows lost HP
- Shows server uptime
- Block join to CT
- Hook
- Restartround 0.1 sec
- Auto-rename recorded demos
- Check attempts to record
- Check legal kz server settings
- Show world records
- Demo recording menu
- Spec List
- All chat
- Cvars
- Removed hudtexts
- Block weapon pickup
- Multiples Communities Records
- Axn bhop (no slowdown, no speed limit)
- Bot replay (best run & last run)

Cvars:
- kz_timer <1|0> - On/Off show timer in roundtime (default: 1)
- kz_attempts <1|0> - On/Off show demo attempts (default: 1)
- kz_wrmsg <3|2|1|0> - Show difference between your time and record time (3 = wr and comm, 2= comm only, 1 = wr only, 0 = Off) (default: 1)
- kz_wrhud <1|0> - Hud/Chat show wr in hud or chat (default: 1)
- kz_currentwrmsg <2|1|0> - Time & Author/Only Time/Off show current wr holder in chat within finish message (default: 1)
- kz_chatmsg <2|1|0> - All/Important/Off hide plugin messages in chat (default: 2)
- kz_blockct <1|0> - On/Off block counter-terrorists (default: 1)
- kz_blocksounds <1|0> - On/Off block start sounds (default: 1)
- kz_speclist <1|0> - On/Off show specs (default: 1)
- kz_allchat <1|0> - On/Off chat between dead and alive players (default: 1)
- kz_blockmapsound <1|0> - On/Off block map sounds (automatic stopsound) (default: 1)
- kz_blockmapweapons <2|1|0> - All weapons/Except dropped weapons/Off block pickup guns (default: 1)
- kz_hookspeed - Set hook speed (default: 500)
- kz_setstarttouch <1|0> - On/Off set start position by touching start button (default: 0)
- kz_allowaircp <1|0> - On/Off allow cps in air (default: 1)
- kz_startcmd <1|0> - Edit what the /start cmd does (1= record a new demo, 0 = move to start position) (default: 1)
- kz_loadangles <3|2|1|0> - Load saved angles (3 = Start & CP, 2= CP only, 1 = Start only, 0 = Off) (default: 1)
- kz_axnbhop <1|0> - On/Off axn bhop (default: 0)
- kz_lasttouch <1|0> - On/Off Allow multiple start hits (default: 0)
- kz_communities - Show community records, this goes along with kz_wrmsg > 2 (default: 0) please dont edit this manually if you dont know what are you doing, use record menu

*if you want to edit kz_communities manually, please take a look at this:

Each community that we add it to the commrecords.ini, has a flag that goes in the cvar. (same order as in commrecords.ini)
This flag is obtained with 2^k = index, k starting from 0 and increasing by 1 for each community.

- if we have 1 community
flag1 = 2^k = 2^0 = 1

- if we have 2 communities
flag1 = 2^k = 2^0 = 1
flag2 = 2^k = 2^1 = 2

- if we have 5 communities
flag1 = 2^k = 2^0 = 1
flag2 = 2^k = 2^1 = 2
flag3 = 2^k = 2^2 = 4
flag4 = 2^k = 2^3 = 8
flag5 = 2^k = 2^3 = 16

The flags are additive between them to have more than one community in the cvar.
- If we want the community1 and comm3, this would be the sum of flag1 + flag3 (1+4)
kz_communities 5
- If we want the community1, comm2 and comm3, this would be the sum of flag1 + flag2 + flag3 (1+2+4)
kz_communities 7
- if you want all communities, this would be the sum of all (1+2+4+8+16)
kz_communities 31

Cfg File
its in configs folder (addons/amxmodx/configs/krdcvars.cfg), edit cvars there :)

Commands
- say /menu, /main, /startmenu - recording menu (only alive and localhost 'm' chooseteam)
- say /settings, /setmenu - settings menu
- say /settings, /setmenu - settings menu
- say /endmenu - finish menu
- say /start (if kz_startcmd equal to 1 record a new demo or if kz_startcmd equal to 0 you will be moved to start position)
- say /records, /recmenu - communities records menu
- say /demo, /kzdemo, /record, /restart - start recording (bind v "say /demo")
- say /stop, /stoprecord - stop recording
- say /timer - enable/disable the timer
- say /setstart - save start position
- say /cp, /checkpoint - save position
- say /tp, /gc, /gocheck - load position
- say /uptime, /up - show server uptime
- say /godmode, /god - enable/disable godmode
- say /noclip, /nc - enable/disable noclip
- say /ct, /spec - move to CT/SPECTATOR (spec team or not localhost 'm' chooseteam)
- say /speclist - show players in spec
- say /wr - show world record
- say /"communitytldname" show community record ( replace 'communitytld with correct community tld name and ignore quote)
- say /stopwatch - make a timer between 2 points.
- say /replay - replay demo options
- say /playback - replay demo options
- +hook - use the Hook ( bind f +hook)

Customizable part (inside plugin)
// BEGIN EDIT
new const Prefix[] = "[KZ]";

new const TempName[] = "lastrecord_file";
new const g_szDirFile[] = "kzrecords";
new const g_szDirFile2[] = "kzaxnmaps";
new const g_szAxnMapFile[] = "maps.ini";
new const g_szCommRecordsFile[] = "commrecords.ini"
new const g_szCvarsFile[] = "krdcvars.cfg"

const MAX_COMMUNITIES = 25; // If you reach 25 communities, this must be incremented.

new const g_szDemoFiles[][][] = // This is wr records (no comm records)
{
{ "http://xtreme-jumps.eu/demos.txt", "demos_xj.txt", "demos_last_update_xj.txt" },
{ "https://cosy-climbing.net/demoz.txt", "demos_cc.txt", "demos_last_update_cc.txt" }
};
// END EDIT

Communities
If you want to add new communities edit commrecords.ini file (/addons/amxmodx/data/kzrecords/commrecords.ini)

commrecords.ini Format:
; Demos URL
; Demos demos file
; Demos update demos file
; Community Name
; Community Tld Name ( say command )

Note: if any community is not working please remove it from commrecords.ini because it does that server take a lot of time to start

Axn Maps
If you want to add new maps edit maps.ini file (/addons/amxmodx/data/kzaxnmaps/maps.ini)
One map per line, please!

* I just added xj maps, please tell me any other axn map!!!

Requirements:
- AMX Mod X 1.8.1 (or higher)
- Orpheu modules

Changelog:
v0.1
- Initial Release
v0.2
- Added communities records
- Fixed some bug with new demos.txt xj file
- Fixed usp ammo and bpammo
- If you are localhost and you are alive m key open menu, otherwise it change team.
v0.3
- added say /endmenu - finish menu
- added say /records, /recmenu - communities records menu
- fixed instant restart
- rewriten kzr_maincommunity and changed to kz_communities, please dont edit this manually use record menu
- kz_wrmsg now has more values please check cvar list
v0.4
- instant restart fixed
- /start command can be edited by cvar if kz_startcmd equal to 1 you record a new demo, otherwise you will move to start position
- finish message has been rewritten
v0.5
- Improved communities records and better customization
-v0.5.1
- minor fix in finish menu
-v0.5.2
- minor fix
- added new cvar kz_loadangles
v0.6
- fixed allchat (stupid bug)
- fixed speclist (stupid bug)
- added a new cvar for current wr message within finish message
- improved menus system
-v0.6.1
- fixed minor print bug
- added an antiflood for those who have the "+ use" with the scroll
-v0.6.2
- fixed minor bug
-v0.6.3
- added a 3th option to finish menu "Accept this demo and start a new one"
-v0.6.4
- fixed the new option in finish menu
v0.7
- code optimization
- added axn bhop
- added a maplist and a cvar for axn
- added a new option to settings menu, it save cvars in krdcvars.cfg
- minor changes
- cvar tag has been changed from krd_ to kz_
-v0.7.1
- fixed wr record holder name in communities, it was not working
- minor change in finish message.
-v0.7.2
- added 2 missed files please if you use 0.7+ version you have to redownload it
-v0.7.3
- fixed speclist it was showing wrong results
-v0.7.4
- fixed roundtime it was showing wrong results due to speclist issue
-v0.7.5
- added if kz_lasttouch is 1, player can hit multiples times the start button. (I don't know if it's allowed, don't use if you aren't sure)
- fixed minor bugs
-v0.7.6
- fixed demo attempts
- fixed hud bug when you join from spectator (tell me if you know a better fix)
-v0.7.7
- fixed spec players due to previous update
-v0.7.8
- improved ct, spec and autojoin functions :)
-v0.8.0
- fixed some bugs, fixed some cvars
- added stopwatch (cmd say /stopwatch)
- dont remember i made this like 5 months ago
- added a feature which you can record a demo and see on your server a bot that replay your run

Note:
- There are some problems with cosy records, they dont get udpated automatically :( because their website use an SSL protocol, so we cant get access to them)

* How to update records manually
- urls
xj records: http://xtreme-jumps.eu/demos.txt
cc records: https://cosy-climbing.net/demoz.txt

- open your addons folder
- go to amxmodx/data/kzrecords/ folder
- make a new txt file named demos_xj.txt for xj maps and demos_cc.txt for cc demos
- copy all the content from url and paste in the corresponding file
- that is all :)

Credits:
- Kr1Zo i took some ideas from their kzdemo plugin
- ConnorMcLeod
- Arkshine

Download:
MediaFire

*If you dont know how to install, download this complete addons MediaFire

what it include?
- default amx 1.8.2
- kz demo
- uq_jumpstats

Suggestions or problems please post it

Greetings, gladius

smiley18/04/2014 03:11

nice job!!

Fantasm18/04/2014 03:39

good work gladius. thats our guy- pro coder!

Creative18/04/2014 06:09

good job gladius

Kiskis18/04/2014 07:58

Possible to make that when you press m button it opens menu? Oterwise, great job!

deidi18/04/2014 10:05

awesome

random Tournament #318/04/2014 13:30(edited 18/04/2014 15:20)

Would be great to add somehow all countries of record list, from the other communities, not only wr's. So you could choose what country record you want to see after you finished map. "You finished map xx:xx:xx ( - xx:xx:xx Russian record )"

EDIT: And I noticed that bullets on usp are not restored after new restart

gladius18/04/2014 23:43

I updated main post, please read changelog and redownload it :)

Nokkan19/04/2014 01:33

when you click m, it writes 1 near the chat

gladius19/04/2014 01:45

Yeaah sorry, I fixed it now :)

TonyStark19/04/2014 04:17

gj gladius !

Nikita19/04/2014 07:04

Nice plugin, but the quick restart isn't instant restart, you should fix that and also it would be cool if you could add in the menu which record it would show, for example...
Showing record: (option 1) WR, (option 2) kz-sca, (option 3) unique-kz etc... just add all communities, that would be great :)

gladius19/04/2014 10:09

I updated plugin, please read changelog

Creative19/04/2014 10:23

set_task(0.1, "DelayWeapons_Task", id);
remove this line for instant restart

gladius19/04/2014 10:26

instant restart is working very well :)

random Tournament #320/04/2014 01:36

instant restart aint working very well, you need to wait a sec or two, to start timer, and I hate that knife is after restart, better would be what wpn you have, that wpn will be after restart. And in kzdemo 1.8 you can just bind /start and it will record new demo, but here you need to type only /kzdemo so I always need to rebind my button when im playing LAN or pub. Everything seems to be good I think. I only liked more kr1z0's plugin that in chat "bkz_goldbhop you finished in 01.26.38 (- 00.02.03)" w/o that New World Record in chat, its kinda obvious that you made wr if it will show ( - ). And World Record was in middle that was better :D Would be great that you could fix everything again. Because I like that you can choose community too, and some other basic things w/o adding them in plugins.ini.

gladius20/04/2014 03:01

I updated plugin, please read changelog.

random please redownload and test now :)

random Tournament #320/04/2014 16:06

Now its great, thanks ;)

memekrecord holder20/04/2014 17:20

Because of those plugins I want to record again. Thank you!

Originally posted by memek
Because of those plugins I want to record again. Thank you!

xmasjourney is awaiting you :D

integrated stopsound or any other sound blocker would ease the life. great job, might be of use for me

Page 1 of 8

Please log in to post replies.