Search found 148 matches

by 8guawong
Mon Oct 06, 2014 5:55 pm
Forum: Plugin Development Support
Topic: need working script that acutally switches player for csgo
Replies: 26
Views: 18894

here is my full code it limits 1 player to T and rest to CT and switched players at then end of the round picking a CT randomly this will switch the players BUT map time WILL restart from commands.client import ClientCommandFilter from players.helpers import edict_from_playerinfo from players.helper...
by 8guawong
Mon Oct 06, 2014 4:45 pm
Forum: Plugin Development Support
Topic: need working script that acutally switches player for csgo
Replies: 26
Views: 18894

sigh~~ can we end the round ourselves?
i'm thinking maybe set mp_ignore_round_win_conditions 1
and just check number of players on each team then fire round_end by ourselves
by 8guawong
Mon Oct 06, 2014 1:51 pm
Forum: Plugin Development Support
Topic: CS:GO giving weapons weird problem
Replies: 10
Views: 7868

Not sure if this is the same problem that I'm facing... so i'll post it here i spawn c4 instead of fb........ so if i don't have c4 it'll spawn one for me but if i drop the c4 and spawn another c4 i can still pick up the c4 that is on the ground :confused: and then sometime you can't drop the c4 an...
by 8guawong
Mon Oct 06, 2014 3:30 am
Forum: Plugin Development Support
Topic: playeriter to count the number or pending team change
Replies: 5
Views: 4719

for player in get_players_in_or_pending_team(2): print(player.name, 'is terrorist!') print('There is', len(set(get_players_in_or_pending_team(3))), 'counter-terrorists!') ok thanks! but could you comment the code? having a hard...
by 8guawong
Mon Oct 06, 2014 3:26 am
Forum: Plugin Development Support
Topic: CS:GO giving weapons weird problem
Replies: 10
Views: 7868

Not sure if this is the same problem that I'm facing... so i'll post it here i spawn c4 instead of fb........ so if i don't have c4 it'll spawn one for me but if i drop the c4 and spawn another c4 i can still pick up the c4 that is on the ground :confused: and then sometime you can't drop the c4 any...
by 8guawong
Mon Oct 06, 2014 3:12 am
Forum: Plugin Development Support
Topic: changing teams
Replies: 3
Views: 3764

This has been asked a few times before: http://www.sourcepython.com/showthread.php?506 yea i know bout that thread just wondering if any of them actually switches player's team this changes the player's pending team but no the actual team <PlayerEntity>.set_team(<value>) <PlayerEntity>.team = <valu...
by 8guawong
Mon Oct 06, 2014 3:03 am
Forum: Plugin Development Support
Topic: need working script that acutally switches player for csgo
Replies: 26
Views: 18894

need working script that acutally switches player for csgo

Hello I've given up on trying... so would some1 make a script for me... :tongue: This script should keep 1 T and rest goes to CT and at round end T will be switched to CT and a random CT will be switched to T also prevent the map time from reseting!! thanks! -----------------------------------------...
by 8guawong
Sun Oct 05, 2014 8:23 am
Forum: Plugin Development Support
Topic: playeriter to count the number or pending team change
Replies: 5
Views: 4719

I don't think adding that to PlayerIter is a good idea cause well, while it is pending, you are "still" in your current team... Also, you can always check that yourself. from filters.players import PlayerIter from players.entity import PlayerEntity def get_players_in_or_pending_team(t...
by 8guawong
Sun Oct 05, 2014 7:08 am
Forum: Plugin Development Support
Topic: playeriter to count the number or pending team change
Replies: 5
Views: 4719

playeriter to count the number or pending team change

argh csgo is so stupid after you choose to switch team your teamid still stay on the old team so is it possible for playeriter to include a filter that includes the pending team change?? example: 1 T and 2 CT 1 CT decided to change team to T len(PlayerIter('t')) == 1 --> should be 2 since one of the...
by 8guawong
Sun Oct 05, 2014 4:37 am
Forum: Plugin Development Support
Topic: changing teams
Replies: 3
Views: 3764

changing teams

<PlayerEntity>.set_team(<value>) <PlayerEntity>.team = <value> <PlayerInfo>.change_team(<value>) <PlayerEntity>.SetTeam(<value>) <PlayerEntity>.InputSetTeam(<value>) <PlayerEntity>.switch_team(<value>) are there any differences??? reason i'm asking if because: on deathrun maps i want 1 T and rest CT...
by 8guawong
Sun Oct 05, 2014 1:28 am
Forum: Plugin Development Support
Topic: Why doesn't this work?
Replies: 5
Views: 4921

Sorry for not replying till now, I forgot about this thread. Are you still having issues with this? I have a couple bits of advice. If you are testing for True and False, you should return those values instead of 1 and 0. Use 1 and 0 when you actually mean to return an integer. Also, the check_play...
by 8guawong
Sat Oct 04, 2014 1:49 pm
Forum: Plugin Development Support
Topic: "Team is full" message
Replies: 8
Views: 7858

take a look at this

https://forums.alliedmods.net/showthread.php?t=219812

i sorta don't wanna use it b/c there is some bugs with it ie. player joining undesired team

can we do something like that with SP?
by 8guawong
Sat Oct 04, 2014 11:45 am
Forum: Plugin Development Support
Topic: Hwo to check if player have c4 or not?
Replies: 1
Views: 2464

Hwo to check if player have c4 or not?

Syntax: Select all

PlayerEntity(index).c4

don't work :smile:
by 8guawong
Fri Oct 03, 2014 11:49 am
Forum: Plugin Development Support
Topic: How to emit sound??
Replies: 22
Views: 19140

ok this works in csgo (linux) from events import Event from players.helpers import edict_from_userid from stringtables.downloads import Downloadables from engines.server import engine_server dl = Downloadables() dl.add("sound/custom/sound.mp3") @Event def player_spawn(g...
by 8guawong
Fri Oct 03, 2014 11:44 am
Forum: Plugin Development Support
Topic: can't put script with stringtable in autoexec.cfg
Replies: 3
Views: 3544

can't put script with stringtable in autoexec.cfg

[SP] Caught an Exception: Traceback (most recent call last): File "../addons/source-python/packages/source-python/plugins/manager.py", line 72, in __missing__ instance = self.instance(plugin_name, self.base_import) File "../addons/source-python/packages/source-python/plugins/instance.py", line 82, ...
by 8guawong
Fri Oct 03, 2014 10:56 am
Forum: Plugin Development Support
Topic: Hiding/silent say trigger
Replies: 2
Views: 3197

You are right, it is not like ES since we give you the choice directly in your callback. from commands import CommandReturn from commands.say import SayCommand # Usage: # @SayCommand(<(str or list) names>, [str level], [str permission], [str flag], [callable fail_callback]) # A sing...
by 8guawong
Fri Oct 03, 2014 6:21 am
Forum: Plugin Development Support
Topic: Hiding/silent say trigger
Replies: 2
Views: 3197

Hiding/silent say trigger

i was looking at

http://wiki.sourcepython.com/index.php/commands

but i don't think its like

es.regsaycmd where the trigger is hidden/silent?

so is there anyway to make the trigger silent???
by 8guawong
Thu Oct 02, 2014 3:01 pm
Forum: Plugin Development Support
Topic: How to emit sound??
Replies: 22
Views: 19140

Hedgehog wrote:Sorry, I forgot to import it...
[python]from engines.sound import engine_sound[/python]

And as I said earlier
Hedgehog wrote:I'm not sure that it will work in CS:GO, but you should try...


ok i'll report back after i tried it
by 8guawong
Thu Oct 02, 2014 8:09 am
Forum: Plugin Development Support
Topic: How to emit sound??
Replies: 22
Views: 19140

Could you add a debug message to show whether or not that event is even working? Also, your precache and client_command lines I don't believe should be including the sound/ directory. The Downloadables does require the sound/ prefix, as you already have it. [SP] Caught an Exception: Traceback (most...
by 8guawong
Thu Oct 02, 2014 8:06 am
Forum: General Discussion
Topic: SP logs locations
Replies: 10
Views: 8502

Sorry, didn't see your's or L'In20Cible's replies prior to mine above when I posted it. so how bout keep the most recent warning message on the TOP of the file instead of the bottom? so we don't have to scroll all the way down? :cool: Logging doesn't work that way. Logging appends the current messa...

Go to advanced search