Raised This Month: $12 Target: $400
 3% 

Showing results 1 to 25 of 420
Search took 0.01 seconds.
Search: Posts Made By: p3tsin
Forum: Scripting 09-08-2010, 12:44
Replies: 13
Views: 2,887
Posted By p3tsin
Re: who can make this?

Does it work with your ES code? Because asherkin's code really is the exact same thing. Also, do the links point directly to .mp3 files or maybe to a media player? I'd suggest using an IE compatible...
Forum: Scripting 09-07-2010, 18:41
Replies: 13
Views: 2,887
Posted By p3tsin
Re: who can make this?

Just for comparison, here's the same thing with ShowVGUIPanel as suggested.

new Handle:kv = CreateKeyValues("data");
KvSetString(kv, "title", "\"Any\"");
KvSetString(kv, "type", "2");...
Forum: Scripting 09-03-2010, 15:24
Replies: 22
Views: 7,471
Posted By p3tsin
Re: PrintToChat - Client index 0 is invalid

0 isn't a client index, it means the command originated from server console (like with dedicated servers). The host usually has a client index of 1. Though I've ran into having a higher client index...
Forum: Scripting 09-01-2010, 15:30
Replies: 25
Views: 14,384
Posted By p3tsin
Re: Dividing the numbers in sourcemod

You'd be writing very bad code if you didn't know if the client was in-game or not before trying to get his kill ratio. Besides, if the execution isn't stopped in this function, it will be when you...
Forum: Scripting 08-24-2010, 15:55
Replies: 12
Views: 5,265
Posted By p3tsin
Re: [CSS] How do i hook "Map end"?

The word you're looking for is "intermission". There should be a few threads about it.



I believe this is controlled by mp_chattime.
Forum: Scripting 08-22-2010, 12:17
Replies: 10
Views: 2,448
Posted By p3tsin
Re: Qs about "native ChangeClientTeam(client, team);"

Oh, sorry my bad. When the op talked about setting offsets he clearly meant netprops/datamaps and I assumed you were referring to them too.
Forum: Scripting 08-20-2010, 08:42
Replies: 10
Views: 2,448
Posted By p3tsin
Re: Qs about "native ChangeClientTeam(client, team);"

Sure, but the op wanted to know how it works and what it actually does. :roll:
Forum: Scripting 08-19-2010, 19:05
Replies: 10
Views: 2,448
Posted By p3tsin
Re: Qs about "native ChangeClientTeam(client, team);"

Wow. So short-sighted to say there are no netprops/datamaps involved just because SourceMod doesn't directly access them.



So you wanna find out how it works? Better buckle up then.

Okay,...
Forum: Scripting 08-16-2010, 12:12
Replies: 5
Views: 1,420
Posted By p3tsin
Re: Cannot think about a desc for this (operators)

Your example code is a rather confusing without a real case situation. But surely you can combine the conditions, and make them if - else if (otherwise one player could increment the count multiple...
Forum: Scripting 08-16-2010, 11:47
Replies: 5
Views: 1,420
Posted By p3tsin
Re: Cannot think about a desc for this (operators)

IsPlayerAlive returns a boolean, 'alive' is a boolean... 1+1=?

get_pcount(bool:alive)
{
new players

for(new x = 1; x <= MaxClients; x++)
{
if(IsClientInGame(x) && IsPlayerAlive(x) ==...
Forum: Scripting 08-04-2010, 13:02
Replies: 10
Views: 2,790
Posted By p3tsin
Forum: Scripting 07-31-2010, 15:14
Replies: 13
Views: 2,799
Posted By p3tsin
Re: How to make SortADTArray() case insensitive?

Or just use strcmp.

SortADTArrayCustom(array,SortMyArray);

//...

public SortMyArray(index1,index2,Handle:array,Handle:hndl) {
decl String:str1[32], String:str2[32]; //replace 32 with array...
Forum: Scripting 07-29-2010, 15:35
Replies: 10
Views: 8,707
Posted By p3tsin
Re: Question about "m_takedamage"

Maybe. I recall trying it out once, but still ended up getting damaged.
Forum: Scripting 07-29-2010, 15:33
Replies: 15
Views: 3,290
Posted By p3tsin
Re: Need help with a plugin I downloaded.

The code wouldn't compile if the function didn't exist. Obviously its declared, but throws a runtime error because of a failed sig scan or something in that direction.

The plugin must be using...
Forum: Scripting 07-29-2010, 15:22
Replies: 10
Views: 8,707
Posted By p3tsin
Re: Question about "m_takedamage"

No, because they don't get hurt.
Forum: Scripting 07-29-2010, 15:20
Replies: 6
Views: 2,076
Posted By p3tsin
Re: weapon string to index

Both methods are totally fine, as long as you're not calling the function tens of thousands of times per second. A delay of 0.000002 seconds isn't really that noticeable :wink:



I just...
Forum: Scripting 07-29-2010, 13:09
Replies: 6
Views: 2,076
Posted By p3tsin
Re: weapon string to index

I used my own benchmark function below to run 200000 cycles (had to increase the heap size in my test plugin). I also optimized both of your lookup functions... get_weapon_hash was using way much...
Forum: Scripting 07-29-2010, 11:50
Replies: 10
Views: 8,707
Posted By p3tsin
Re: Question about "m_takedamage"

Not that it really matters in this case, but the range of a single byte goes from -128 to 127 (or from 0 to 255 if unsigned)
Forum: Scripting 07-28-2010, 09:03
Replies: 13
Views: 3,885
Posted By p3tsin
Forum: Scripting 07-24-2010, 18:10
Replies: 11
Views: 4,158
Posted By p3tsin
Re: Block crouching and jumping?

m_flGravity isn't networked, so it will mess client predictions as well. If you really wanna alter the gravity, I'd suggest using it in combination with SendConVarValue...
Forum: Scripting 07-22-2010, 11:05
Replies: 1
Views: 1,572
Posted By p3tsin
Re: SetupMuzzle position

Sure. Hook it with AddTempEntHook (http://docs.sourcemod.net/api/index.php?fastload=show&id=559&) and then read the parameters one by one as they are written into the tempentity message (take a look...
Forum: Scripting 07-21-2010, 13:18
Replies: 4
Views: 1,356
Posted By p3tsin
Re: FakePlayer +attack?

That makes all bots attack.
Forum: Scripting 07-21-2010, 11:54
Replies: 4
Views: 1,356
Posted By p3tsin
Re: FakePlayer +attack?

What you mean?

#include <sdktools>

public Action:OnPlayerRunCmd(client,&buttons,&impulse,Float:vel[3],Float:angles[3],&weapon) {
if(IsFakeClient(client)) {
buttons |= IN_ATTACK;
}
}
Forum: Scripting 07-18-2010, 11:57
Replies: 15
Views: 3,627
Posted By p3tsin
Re: I want to write a Earth Quake effect!!!

You don't need to do that. Just use the snippet dirka_dirka posted.

Don't forget to credit the original author if you end up releasing the plugin, I wish people would do that when posting snippets...
Forum: Scripting 07-17-2010, 16:02
Replies: 18
Views: 4,353
Posted By p3tsin
Re: Is this a StrCat bug?

No it won't. It will initialize the var with that value, as long as its a constant.
You should know this as a veteran member.
Showing results 1 to 25 of 420

 
Forum Jump

All times are GMT -4. The time now is 05:58.


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