PDA

View Full Version : Howdy, was forwarded here by a fella from modtheatre


Buzz_Litebeer
12-03-2002, 02:11 PM
I have created a modification that can force a players skin, honesty config variables, forcemodels etc (similar to dogmeats in function) with the notable exception that it can be controlled by rcon.

IE you can type rcon <password> security_forceskin 1 and it turns the skin forcer on etc.

The issue is, since having been on several forums now it has come to my attention the limitations of items that can be gleaned from the $player array in scripting. So the idea i have is to get someone such as the creater of delator, or the autokick mod (note crowking) to create a parser on the client side, while someone runs a mod like mine or similar in that it has a rcon interface.

No, i dont even particularly care if it is my mod it interfaces with, but what I would like to do is have the ability of instead of kicking a player with an invalid skin, it would instead change his skin against his will.

I can do this currently with my mod, but the method is inelegant.

But if it could be made to somehow interface with the server, that would be spectacular.

Right now i have not found a way to find an identifier in the player array (whether that be the ip, client id, or name) so if someone can find a UNIQUE value that can be taken from the player array then please tell me, this would solve all my problems ;-)

anyway how i individiually force people to get them to commit suicide change teams or go to spectator is

I have maid a command when set to 1 will send the following stuff text to the players (from an incrementing for loop)

for(local.p++ etc etc)

player[local.p] stufftext "say " + local.p

which makes all the players print out their position int he client array.

these numbers change all the time though, so the next commands have to be done fast.

but then i send a command based on the number their character says and it does that command on them.

for example

if i typed switch_allies <playerarraynumber>

it would then take that player array number, and then stuff the text to

$player[<playerarraynumber>] stufftext "join_team allies"

right now this is all working.

I also have a program that can parse and boot based on model, unfortunatly i spent a lot of time writing the bastard only to find out that the models are all the same, its the skins i need to look at ;-)

so basically I have a massive switch statment waiting to be used for a good cause.

So again, the idea is that someone such as crowking might be able to create a mod that maybe it doesnt do much except to work in concert with a person on the server, the person on the server could get the flag from crowkings mod then do the skin change manually.

Or if someone here is particularly clever, and knows of a way to retrieve a SINGLE primary key variable from the $player array, or some other array that would help, then please post!

A primary key from $player would be

The players name

The players clientid

The players IP address

and thats it ;-(

so if anyone knows how to pull any of those out of the player array, or some other array that can be used to find an index for the player array, then this can all be done seemlessly with a crowking or delator type rcon interface program.

Even if someone doesnt work with me (though i hvae already done all the code to do all of this and it would be simple to implement it based on a primary key and would be done within... oh 20 minutes of being notified of what that primary key was) i would love to see it done, because it would really help keep the lazy cheaters at bay (i know it wont stop the really really determined shits who screw up the universe but hey)

I also have 3 other mods

I have a bind mod (client side) which adds binding so that you can set a primary weapon button (ie it always goes to the primary weapon you are holding, regardless of what it is)

and a mod that limits voting to kicking in spearhead (trivial i know but i did the work for someone so they dont have to)

Buzz OUT

Daffy
11-13-2003, 07:05 PM
Ok Buzz,

I spent the whole damn afternoon reading your posts looking for the answer to these same questions (Finally did a search on Player Array). :hug:

So, did you ever find out the answer to the question Q.can I stuff a value into the clients Player Array and have it read? (I dont know how often the client checks the current value of the array see).

I posted elsewhere what I want to do. I just want to bind a couple of cmds to stuff low health or runspeed or the like to a client from rcon. The rcon menu Bouncer made has some of what I want. I planned to write the program myself until I started looking at MAM. So is it possible with MAM or do I need to look at CI?

Buzz_Litebeer
11-13-2003, 08:03 PM
you can send values to the client, but you cannot read client cvars...