EventScripts Forums
Mattie's EventScripts and Source Forums
Mattie recommends...
Premier Sponsor:Platinum Sponsor:
 
Script Categories
addon (49) admin (269) admins (14) advert (15) adverts (19) afk (15) alerts (12) ammo (23) anti (15) auth (16) automatic (12) awp (23) ban (18) ba_jail (17) bhop (19) block (19) bomb (40) bonus (23) bot (24) bot-management (19) bots (17) bunnyhop (11) Buy (21) cash (65) chat (57) cheat (11) clan (16) classes (22) color (21) colors (18) command (20) commands (18) config (22) connect (42) CS:S (16) css (2507) Damage (35) database (11) dead (15) death (19) deathmatch (70) deathrun (12) disconnect (18) Dissolve (11) dm (20) dod:s (11) dods (389) easy (17) effects (120) English (15) entity (21) es_tools (12) Eventscript (12) flashbang (25) français (99) french (36) fun (288) funny (16) Gabeee (11) gameplay (174) give (16) gravity (11) grenade (25) grenades (29) gun (14) GunGame (26) GunGame5 (11) guns (17) Hack (15) headshot (32) health (55) hegrenade (13) hl2dm (332) HP (13) info (48) information (16) jail (26) jailbreak (11) join (23) jump (12) kick (23) kill (44) kills (22) knife (57) leveling (36) management (14) mani (15) map (25) map-management (27) maps (15) match (17) menu (106) message (20) messaging (52) mod (109) model (14) models (32) money (42) motd (13) music (29) mute (18) nades (18) name (13) noblock (35) player (40) player-management (31) player-tracking (28) popup (56) props (23) protection (27) punishment (50) python (63) quake (18) radio (21) random (36) rank (35) rates (16) rcon (13) realism (21) respawn (61) restrict (36) round (20) rpg (24) rules (42) say (11) scout (19) Script (20) script-helper (25) scriptpack (33) sdk (151) server (44) server-tools (42) shop (12) silly (31) simple (27) skins (25) slay (13) soccer (11) sound (45) sounds (92) spawn (63) speed (25) statistics (13) stats (48) STEAMID (23) Superhero (13) surf (31) Team (25) team-balance (14) teleport (12) text (14) TF2 (143) time (17) timer (14) tools (15) tracers (17) triggers (11) uedi (18) uses_auth (18) utility (11) vip (12) vote (36) voting (22) war (20) wcs (24) wcs:Python (32) weapon (77) weapons (114) web (14) welcome (12) zm (24) zombie (90) zombiemod (51) zombies (11)
Script Authors
*XYZ*SaYnt (12) .:MiB:. (11) .eMko* (6) 101satoon101 (10) 3R10N (24) 4u571n91 (5) 7355608 (9) Absolute (8) Ace Rimmer (40) adminc (5) Adz (8) AgathaKnuppelkuh (8) aidden (8) ajax (5) ak_47 (6) Al3c Tr3v3lyan (6) allstareng (5) ashbash1987 (9) ATAMAH (7) aznone (5) B00M (5) BackRaw (41) BFH_RedBull (8) bigfabi (7) Bioko (7) Blade (10) bladesback (13) bobdole (11) bodzsar1 (8) bonbon (36) Brainsucker (30) cagemonkey (8) carbon-14 (10) CaskioUTF (5) cbirou (15) ChaCaLz2psy4 (5) CharlesT (5) Chrisber (5) chrismrulz (9) Chun (6) cladiron (10) clipz934 (8) Colster (21) Cookieman8 (7) craziest (10) DanielB (19) Darkness123 (8) Dave (9) dbozan99 (7) deathx9 (5) Deathyy (16) dhack (16) Di[M]aN (12) DoCky (27) Don (15) dordtcore (8) DragonFreddo (8) Drassil (5) Einlanzers (42) EmbouT (10) emilplov (7) Errant (10) Eun (6) Fantole (9) Franc1sco (9) freddukes (18) Frequency (6) Fulmine (5) GAMEREN2 (8) german9114 (13) GODJonez (38) GoodfellaDeal (5) Hansi (6) HitThePipe (7) HOLLDIDAY (9) Icetouch (6) ichthys (25) infamous1 (9) Jeff91 (45) JoeyT2006 (30) Juba_PornBorn (12) jxl180 (10) KDBFame (6) L'In20Cible (7) Largo Usagi (10) Lobe (11) loKkdoKk (7) lolo-le-haricot (7) LosNir (5) Lumpi@Work (9) M4rc3L-XCN (7) macshot (6) Matth (6) Mattie (20) MBchrono (15) McFly (20) Medda (5) Memphis-84 (10) Messiah93 (12) Mickyy (5) micmacx (6) Mitchell (5) Mordavolt (7) MrScriptaz (5) mryoung (6) Nicolous (26) ojii (31) Omega_K2 (8) Owned|Myself (8) P3N (7) pand3mic (5) parsimba (5) Pascal257 (9) PatPeter (7) PDrop (10) Phaedrus (18) PhantOm Fury (7) phoenix131 (9) pinkyyy -.- (5) pitbull0993 (7) randomknifer (9) Ratzee (6) ReaCtioN2oo9 (6) Rennnyyy (17) revolutionfighters (6) RideGuy (12) Rio (9) Roeliekt (6) runamagic (13) sandking220 (6) Sarcasm_Poisoning (10) saRs| Johnny-5 (13) Schubaal (10) sea212 (5) sega74rus (7) sgt.angel (6) sicilia (5) sicman_adrian (22) skillz92 (7) sn4k3 (18) snake38 (10) sonicsight (7) spoonman184 (8) stabby (22) stas (22) Strontium Dog (30) SumGuy14 (25) SuperDave (45) surfteam (5) TaCo (5) TanaToS (17) Tealk (6) teowow (16) TheCheeTaH (20) TheDonFather (5) theresthatguy (6) Tiny Tod (7) Totyahun (9) uedi (38) Undead (25) usernamesaretaken (15) Warren (13) westham (6) WhiteAvenger (7) Wonder (14) X-Mania (5) XE_ManUp (13) xfalcon61 (5) zSweetXz (5) [Cs]Lord_Inferno2 (11) [NATO]Hunter (28) ||Wolf|| (10)
Search

Post new topic Reply to topic
Go to page 1, 2, 3, 4, 5, 6  Next
Author Message
User avatar
Site Administrator
Site Administrator
Profile

Posts: 7438
Location:
At Work
 
New postPosted: 2005-06-18, 1:21 pm 
   Post subject: OWNED Script Pack by Mattie

What player has 0wn3d you the most? This script pack counts your deaths by each other player and remembers it forever.

http://mattie.info/downloads/owned.zip

The script pack does the following:
    1. If a player says "!owned", it will announce the player that '0wnz' him, i.e. the player who has killed them the most.
    2. Whenever a player dies, a check is made to see if the killer is the new '0wn3r'. If they are, an announcement is made.
    3. Keeps track of killers/victims, etc, and stores them to disk each round.
Installation:
    1. Extract all of the owned.zip files into an "owned" subdirectory underneath your eventscripts subdirectory (e.g. cstrike/cfg/events/owned)
    2. Add "eventscripts_register owned" to your autoexec.cfg
    3. Restart your server
Enjoy!
-Mattie


Last edited by Mattie on 2006-05-16, 11:34 pm, edited 3 times in total.




User avatar
 
New postPosted: 2005-06-18, 8:19 pm 

Absolute class Mattie! :)


User avatar
Moderator
Moderator
Profile

Posts: 3171
Location:
10,000 feet

Steam Friends Name: Phil Pendlebury
 
New postPosted: 2005-06-18, 8:50 pm 

LOL. That was me again. Forgetting to log in.

Mattie, where is the owned info stored? I just tried it out by letting a load of bots kill me over and over and woudl like to either edit or reset the file.

It seems that now any time any bot is on the server he is my 0wn3r. I presume this is becuase the data is tamen from stam ID of which bots are all teh same.

I'll have a look through the script but I have a feeling this may be beyond me.

Even after finding the es_owned_db.txt on my server it doesn't look any different from the original one in the zip file.

I have edited a little of the messages and change the say trigger to "owned?"

AND

Is it difiicult to add:

"Owning?"

Lists the player or players that you are currently owning?


FURTHER EDIT:

Yes it woudl be great to add the abililty to NOT include bots in the owenrship. I'm sure that would be easy to add but I must admit the new key value stuff has beaten me.
:lol:

_________________
How To: Download Ace Event Scripts (2010)
How To: Install ES + Scripts
How To: Get Scripts Running (for users)
How To: Get Scripts Running (for scripters)
How To: Using the MACE Clients Converter

Phil Pendlebury (Ace Rimmer)

http://www.pendlebury.biz - http://www.meap.biz - http://www.riffsandrays.com


User avatar
Site Administrator
Site Administrator
Profile

Posts: 7438
Location:
At Work
 
New postPosted: 2005-06-18, 11:29 pm 

Ace Rimmer wrote:
LOL. That was me again. Forgetting to log in.

Mattie, where is the owned info stored? I just tried it out by letting a load of bots kill me over and over and woudl like to either edit or reset the file.

It seems that now any time any bot is on the server he is my 0wn3r. I presume this is becuase the data is tamen from stam ID of which bots are all teh same.

I'll have a look through the script but I have a feeling this may be beyond me.

Even after finding the es_owned_db.txt on my server it doesn't look any different from the original one in the zip file.

I have edited a little of the messages and change the say trigger to "owned?"

AND

Is it difiicult to add:

"Owning?"

Lists the player or players that you are currently owning?


FURTHER EDIT:

Yes it woudl be great to add the abililty to NOT include bots in the owenrship. I'm sure that would be easy to add but I must admit the new key value stuff has beaten me.
:lol:


Yeah, it's easy to exclude bots. Just do an es_isbot on the attacker in player_death and test if it's 1. I just excluded it from this version. I definitely do not recommend trying it with bots unless you add a check like that.

I'll update the key value documentation when I get a moment. It's not very intuitive, I must admit. I'm just hoping its power will draw enough people into it to get some good examples flowing out there.

As for adding a new command to list everyone you own, I definitely plan to do that. Unfortunately, the command to do that isn't yet in eventscripts (es_foreachval) so I couldn't put it in. It would be trivial to track and store the single person you have killed the most (not all the people you own, just the most 0wn3d). You pretty much just reverse the logic of this script pack.

If no one else gets around to writing a script pack for that, I shall.

By the way, when playing with es_keygroup, es_keysetvalue, etc, the es_keylist and es_keygrouplist commands are your friends. They're very handy for displaying all the information in memory.

The database should be stored in-place on disk in the 'owner' script pack directory. That's odd that it hadn't updated because it should do so at every round_end unless permissions aren't correct for the file.

If you want to reset what's in memory on the server, type es_keygroupdelete owned. Then put the original es_owned_db.txt back into place and restart the server.

Let me know if you're not able to figure this last part out, and I'll work with you more to track down the problem.

Thanks,
-Mattie


User avatar
Site Administrator
Site Administrator
Profile

Posts: 7438
Location:
At Work
 
New postPosted: 2005-06-18, 11:46 pm 

Ace Rimmer wrote:
LOL. That was me again. Forgetting to log in.

Mattie, where is the owned info stored? I just tried it out by letting a load of bots kill me over and over and woudl like to either edit or reset the file.

It seems that now any time any bot is on the server he is my 0wn3r. I presume this is becuase the data is tamen from stam ID of which bots are all teh same.

I'll have a look through the script but I have a feeling this may be beyond me.

Even after finding the es_owned_db.txt on my server it doesn't look any different from the original one in the zip file.

I have edited a little of the messages and change the say trigger to "owned?"

AND

Is it difiicult to add:

"Owning?"

Lists the player or players that you are currently owning?


FURTHER EDIT:

Yes it woudl be great to add the abililty to NOT include bots in the owenrship. I'm sure that would be easy to add but I must admit the new key value stuff has beaten me.
:lol:


Yeah, it's easy to exclude bots. Just do an es_isbot on the attacker in player_death and test if it's 1. I just excluded it from this version. I definitely do not recommend trying it with bots unless you add a check like that.

I'll update the key value documentation when I get a moment. It's not very intuitive, I must admit. I'm just hoping its power will draw enough people into it to get some good examples flowing out there.

As for adding a new command to list everyone you own, I definitely plan to do that. Unfortunately, the command to do that isn't yet in eventscripts (es_foreachval) so I couldn't put it in. It would be trivial to track and store the single person you have killed the most (not all the people you own, just the most 0wn3d). You pretty much just reverse the logic of this script pack.

If no one else gets around to writing a script pack for that, I shall.

By the way, when playing with es_keygroup, es_keysetvalue, etc, the es_keylist and es_keygrouplist commands are your friends. They're very handy for displaying all the information in memory.

The database should be stored in-place on disk in the 'owner' script pack directory. That's odd that it hadn't updated because it should do so at every round_end unless permissions aren't correct for the file.

If you want to reset what's in memory on the server, type es_keygroupdelete owned. Then put the original es_owned_db.txt back into place and restart the server.

Let me know if you're not able to figure this last part out, and I'll work with you more to track down the problem.

Thanks,
-Mattie


User avatar
Moderator
Moderator
Profile

Posts: 3171
Location:
10,000 feet

Steam Friends Name: Phil Pendlebury
 
New postPosted: 2005-06-19, 9:42 am 

Hi Mattie, Thanks for your info it's starting to make sense now.

Is there any chance you can do that anti BOT edit for me? I can't figure out which line to edit.

This would be so helpful...



Also just listing your own top owner with "owning?" would be cool. But I know this is more than just editing one line.

BTW. The file is now updating I changed the permissions to 777 and all is fine. It also helps to study this file to figure out how it works.

_________________
How To: Download Ace Event Scripts (2010)
How To: Install ES + Scripts
How To: Get Scripts Running (for users)
How To: Get Scripts Running (for scripters)
How To: Using the MACE Clients Converter

Phil Pendlebury (Ace Rimmer)

http://www.pendlebury.biz - http://www.meap.biz - http://www.riffsandrays.com


User avatar
Guru
Guru
Profile

Posts: 1332
Location:
Land O' Too Many Lakes

Steam Friends Name: Maban
 
New postPosted: 2005-06-19, 9:59 am 

And the winner of the first double post goes to Mattie. Congratulations.
Also, why degrade yourself by saying that you're the newbie and not ace?
I mean jeez, WHO made the mod, WHO'S got the mad server, WHO'S the administrator of both?
Hmm...google toolbar suggested jeez instead of geez, so that's what I used.


User avatar
Moderator
Moderator
Profile

Posts: 3171
Location:
10,000 feet

Steam Friends Name: Phil Pendlebury
 
New postPosted: 2005-06-19, 10:03 am 

Maban wrote:
And the winner of the first double post goes to Mattie. Congratulations.
Also, why degrade yourself by saying that you're the newbie and not ace?
I mean jeez, WHO made the mod, WHO'S got the mad server, WHO'S the administrator of both?
Hmm...google toolbar suggested jeez instead of geez, so that's what I used.



And who the hell are you to call me a newbie?

_________________
How To: Download Ace Event Scripts (2010)
How To: Install ES + Scripts
How To: Get Scripts Running (for users)
How To: Get Scripts Running (for scripters)
How To: Using the MACE Clients Converter

Phil Pendlebury (Ace Rimmer)

http://www.pendlebury.biz - http://www.meap.biz - http://www.riffsandrays.com


Last edited by Ace Rimmer on 2005-06-19, 10:05 am, edited 1 time in total.

User avatar
Guru
Guru
Profile

Posts: 1332
Location:
Land O' Too Many Lakes

Steam Friends Name: Maban
 
New postPosted: 2005-06-19, 10:04 am 

Yes, I see your point but I am learning.


User avatar
Moderator
Moderator
Profile

Posts: 3171
Location:
10,000 feet

Steam Friends Name: Phil Pendlebury
 
New postPosted: 2005-06-19, 10:18 am 

OK Mattie I have attempted to edit the code. I feel sure I have added more "if thens" than actually required but here it is. Please edit and correct if you can:

server.cfg
Code:
// 2 extra variables to use for bot testing spawn and death
es_xsetinfo valids 0
es_xsetinfo validd 0


player_spawn.cfg
Code:
// tests for bot and if not sets valids to zero
es_isbot valids event_var(es_steamid)

if (server_var(valids) equalto 0) then es_keycreate owned event_var(es_steamid)
if (server_var(valids) equalto 0) then es_keysetvalue owned event_var(es_steamid) recent_name event_var(es_username)


player_death.cfg
Code:
// tests for bot and if not sets validd to zero
es_isbot validd event_var(es_steamid)

if (server_var(validd) equalto 0) then es_keycreate owned event_var(es_steamid)
if (server_var(validd) equalto 0) then es_keygetvalue owned_killcount owned event_var(es_steamid) event_var(es_attackersteamid)
if (server_var(validd) equalto 0) then if (server_var(owned_killcount) equalto 0) then es_xsetinfo owned_killcount 0
if (server_var(validd) equalto 0) then es_xmath owned_killcount + 1
if (server_var(validd) equalto 0) then es_keysetvalue owned event_var(es_steamid) event_var(es_attackersteamid) server_var(owned_killcount)

// get the old owner
if (server_var(validd) equalto 0) then es_keygetvalue owned_owner owned event_var(es_steamid) owned_by
if (server_var(validd) equalto 0) then es_keygetvalue owned_prevcount owned event_var(es_steamid) server_var(owned_owner)
if (server_var(validd) equalto 0) then if (server_var(owned_prevcount) lessthan server_var(owned_killcount)) then es_xkeysetvalue owned event_var(es_steamid) owned_by event_var(es_attackersteamid)
if (server_var(validd) equalto 0) then if (server_var(owned_prevcount) lessthan server_var(owned_killcount)) then es_msg #green event_var(es_username) is now 0wn3d by event_var(es_attackername)! ( server_var(owned_killcount) deaths! )




I wasn't sure how many of the lines needed checking for bots so added to all of them. Also in player_spawn I thought it was important to check there too as looking in the data file you noitice that bots themselves are getting a record added.

I am about to test this now.

EDIT

Balls it doesn't work.

Just keeps saying you are not owned by anyone. Oh well, back to the drawing board.

_________________
How To: Download Ace Event Scripts (2010)
How To: Install ES + Scripts
How To: Get Scripts Running (for users)
How To: Get Scripts Running (for scripters)
How To: Using the MACE Clients Converter

Phil Pendlebury (Ace Rimmer)

http://www.pendlebury.biz - http://www.meap.biz - http://www.riffsandrays.com


User avatar
 
New postPosted: 2005-06-19, 12:55 pm 

I had a problem with this pack on my servers. Whenever a kill was made it would always display the "blaa is now owned by blaa (1 kill)" or whatever. It would never count more than one kill.. and would change between people each rounds.


User avatar
Site Administrator
Site Administrator
Profile

Posts: 7438
Location:
At Work
 
New postPosted: 2005-06-19, 1:28 pm 

Anonymous wrote:
I had a problem with this pack on my servers. Whenever a kill was made it would always display the "blaa is now owned by blaa (1 kill)" or whatever. It would never count more than one kill.. and would change between people each rounds.


Okay, it's hard to tell from your description what the problem is. I'll mention that this script won't ever work on a machine that is Linux and uses srcds_i486 or srcds_amd for the dedicated server. The behavior you're seeing sounds a little like that.

It's also possible that you're just not patient enough. The first time anyone is killed, they will get their first 0wn3r, and it will be announced as 1 kill. That same person should never get an announcement again until someone ELSE has killed them more than the person who killed them the first time.

E.g., let's say I killed Ajax, it would say something like:
Ajax is now 0wn3d by Mattie! (1 kills)

Then, if Ace Rimmer killed Ajax, nothing would show, but Ace's internal kill count against Ajax will go higher.

If Mattie then again kills Ajax, Mattie's internal count will increase against Ajax.

If Ace Rimmer then kills Ajax again, he's still not higher than Mattie's best count, so nothing will show.

In this way, it's possible that no one ever takes ownership away from Mattie, as long as he keeps killing. As such, you may never see another announcement again.

Still, it should show the appropriate deaths when a player says "!owned". After a few rounds of the same people, you should definitely have some that have more than 1 death (unless you're on amd or i486).

-Mattie


User avatar
Moderator
Moderator
Profile

Posts: 792
 
New postPosted: 2005-06-19, 5:10 pm 

please stop killing me... i'm case-sensitive.

:)


User avatar
Site Administrator
Site Administrator
Profile

Posts: 7438
Location:
At Work
 
New postPosted: 2005-06-19, 5:19 pm 

Ace Rimmer wrote:
player_spawn.cfg
Code:
// tests for bot and if not sets valids to zero
es_isbot valids event_var(es_steamid)

if (server_var(valids) equalto 0) then es_keycreate owned event_var(es_steamid)
if (server_var(valids) equalto 0) then es_keysetvalue owned event_var(es_steamid) recent_name event_var(es_username)


player_death.cfg
Code:
// tests for bot and if not sets validd to zero
es_isbot validd event_var(es_steamid)

if (server_var(validd) equalto 0) then es_keycreate owned event_var(es_steamid)
if (server_var(validd) equalto 0) then es_keygetvalue owned_killcount owned event_var(es_steamid) event_var(es_attackersteamid)
if (server_var(validd) equalto 0) then if (server_var(owned_killcount) equalto 0) then es_xsetinfo owned_killcount 0
if (server_var(validd) equalto 0) then es_xmath owned_killcount + 1
if (server_var(validd) equalto 0) then es_keysetvalue owned event_var(es_steamid) event_var(es_attackersteamid) server_var(owned_killcount)

// get the old owner
if (server_var(validd) equalto 0) then es_keygetvalue owned_owner owned event_var(es_steamid) owned_by
if (server_var(validd) equalto 0) then es_keygetvalue owned_prevcount owned event_var(es_steamid) server_var(owned_owner)
if (server_var(validd) equalto 0) then if (server_var(owned_prevcount) lessthan server_var(owned_killcount)) then es_xkeysetvalue owned event_var(es_steamid) owned_by event_var(es_attackersteamid)
if (server_var(validd) equalto 0) then if (server_var(owned_prevcount) lessthan server_var(owned_killcount)) then es_msg #green event_var(es_username) is now 0wn3d by event_var(es_attackername)! ( server_var(owned_killcount) deaths! )


[...]

EDIT

Balls it doesn't work.

Just keeps saying you are not owned by anyone. Oh well, back to the drawing board.


es_isbot requires event_var(userid)-- it doesn't work with steamid. Try that instead and this code will probably work a good bit better. ;)

-Mattie


User avatar
Site Administrator
Site Administrator
Profile

Posts: 7438
Location:
At Work
 
New postPosted: 2005-06-19, 5:20 pm 

ajax wrote:
please stop killing me... i'm case-sensitive.

:)


Sorry about the 'A'-- we must have been killing someone else. ;)

-Mattie


User avatar
Guru
Guru
Profile

Posts: 1332
Location:
Land O' Too Many Lakes

Steam Friends Name: Maban
 
New postPosted: 2005-06-19, 5:22 pm 

Quick question. When a team mate kills you does their count against you increase? If not it should. You should be able to go out in the street and a friend comes along and knifes you right there. But the question is: Does he get credit for the killing? Just to put things into a real life scenario, odd, but real life.


User avatar
Site Administrator
Site Administrator
Profile

Posts: 7438
Location:
At Work
 
New postPosted: 2005-06-19, 5:26 pm 

Maban wrote:
Quick question. When a team mate kills you does their count against you increase? If not it should. You should be able to go out in the street and a friend comes along and knifes you right there. But the question is: Does he get credit for the killing? Just to put things into a real life scenario, odd, but real life.


Yep! If you kill a teammate it increases your killcount of the person and can make you their new 0wn3r. I actually meant to turn-off that 'feature' because I definitely don't wanna encourage team kills.

Still, I'll leave it in for now. Easy enough for people to fix, if they hate it.
-Mattie


User avatar
Guru
Guru
Profile

Posts: 1332
Location:
Land O' Too Many Lakes

Steam Friends Name: Maban
 
New postPosted: 2005-06-19, 5:29 pm 

I wouldn't want to kill a friend for fun. Nope, I'm a safe guy. :twisted:


Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 93 posts ]  Go to page 1, 2, 3, 4, 5, 6  Next


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group