Raised This Month: $ Target: $400
 0% 

TeamSwitch


Post New Thread Reply   
 
Thread Tools Display Modes
Snake60
Senior Member
Join Date: Jul 2008
Location: Russia, Pskov
Old 03-03-2009 , 10:56   Re: TeamSwitch
Reply With Quote #121

It seems that we can not see the author for a long time, therefore if we want to make something we must do it by ourself. I make some wishes that be here.
1) First of all, I add translation support (Now it in English and Russian - add your if you wish. See file teamswitch.phrases.txt)
2) I add the length of players name so long as allow the source engine (see screens)


3) I cut command name TERR to T (see screen above)
4) I add some colours to the chat report (see screen)
Attached Files
File Type: smx teamswitch.smx (9.5 KB, 431 views)
File Type: sp Get Plugin or Get Source (teamswitch.sp - 879 views - 15.8 KB)
File Type: txt teamswitch.phrases.txt (1.7 KB, 418 views)
File Type: zip TeamSwitch.zip (30.2 KB, 1507 views)

Last edited by Snake60; 03-03-2009 at 10:59.
Snake60 is offline
Send a message via ICQ to Snake60 Send a message via MSN to Snake60 Send a message via Skype™ to Snake60
MuXeu
Member
Join Date: Mar 2004
Location: Kharkov UA
Old 03-03-2009 , 12:38   Re: TeamSwitch
Reply With Quote #122

Snake60: good job, but:
Code:
[muxeu@sila scripting]$ ./spcomp teamswitch.sp
SourcePawn Compiler 1.1.2
Copyright (c) 1997-2006, ITB CompuPhase, (C)2004-2008 AlliedModders, LLC

teamswitch.sp(136) : warning 217: loose indentation
teamswitch.sp(159) : warning 217: loose indentation
teamswitch.sp(196) : warning 217: loose indentation
teamswitch.sp(230) : warning 217: loose indentation
Header size:           3888 bytes
Code size:             9736 bytes
Data size:             3076 bytes
Stack/heap size:      16384 bytes; Total requirements:   33084 bytes

4 Warnings.
__________________
MuXeu is offline
Send a message via ICQ to MuXeu
Snake60
Senior Member
Join Date: Jul 2008
Location: Russia, Pskov
Old 03-03-2009 , 13:56   Re: TeamSwitch
Reply With Quote #123

Yes, I knew it. This warnings about tag else, and I don't understand why compiler angry on it. I am not coders, I am readers of others scripts And I am try to make like in it. But this is simple warning, not error, and plugin seems work good. But I find one thing when translate it. I never see in game this phrases:
Quote:
"[SM] <PlayerName> will (not) be switched to opposite team on their death (end round)."
"[SM] Admin switched <PlayerName> to opposite team." and e.c.
I only see this one phrase when admin make any switches:
Quote:
"[SM] <PlayerName> has been switched by admin."
This is in original version of plugin and in my edition too =/
Why so? I don't know
If here any coders, can you read the code of this useful plugin and find mistakes?

Last edited by Snake60; 03-03-2009 at 13:59.
Snake60 is offline
Send a message via ICQ to Snake60 Send a message via MSN to Snake60 Send a message via Skype™ to Snake60
Snake60
Senior Member
Join Date: Jul 2008
Location: Russia, Pskov
Old 03-13-2009 , 04:57   Re: TeamSwitch
Reply With Quote #124

I find another bug... When player T with bomb switched immediatly in CT team, he don't drop the bomb and skin don't switched too (as I say before). Can anybody fix it?
Snake60 is offline
Send a message via ICQ to Snake60 Send a message via MSN to Snake60 Send a message via Skype™ to Snake60
bobbobagan
SourceMod Donor
Join Date: May 2007
Location: New Zealand
Old 03-15-2009 , 03:07   Re: TeamSwitch
Reply With Quote #125

Thanks a lot for your work Snake, can you also fix the bug where the player names get all shuffled after selecting them?

Just incase you select the wrong person, you can easily unselect them without having to try and find their name again. Just like Mani-Admin.
__________________
bobbobagan is offline
Send a message via Skype™ to bobbobagan
Snake60
Senior Member
Join Date: Jul 2008
Location: Russia, Pskov
Old 04-01-2009 , 05:44   Re: TeamSwitch
Reply With Quote #126

Glad to represent you new version of this plugin. (My hard work about 2 week, because I only start learning SourcePawn)
TeamSwitch
Version 1.4

Changes:
  • Change player skin when switch immediately (for CS:S)
  • Drop bomb when T switch to CT (Thanks Dalto for this part of code)
  • Add announce in chat when admins switch from menu
  • Increase length of players name in menu
  • Add translation support (RU, EN)
Dependencies:
SourceMod 1.2.0 or higher

Installations:
Unzip TeamSwitch.zip to your mod folder

To do list:
May be sorting players in menu (when I'll become more clever in SP )
Attached Files
File Type: zip translations.zip (1.3 KB, 907 views)
File Type: smx teamswitch.smx (10.6 KB, 903 views)
File Type: sp Get Plugin or Get Source (teamswitch.sp - 2298 views - 19.3 KB)
File Type: zip TeamSwitch.zip (19.0 KB, 1645 views)
File Type: txt botdropbomb.games.txt (265 Bytes, 653 views)
__________________

Last edited by Snake60; 12-16-2010 at 07:59. Reason: Update botdropbomb.games.txt
Snake60 is offline
Send a message via ICQ to Snake60 Send a message via MSN to Snake60 Send a message via Skype™ to Snake60
MistaGee
Senior Member
Join Date: Aug 2004
Location: Germany (Fulda)
Old 04-01-2009 , 06:20   Re: TeamSwitch
Reply With Quote #127

Hi,

cool that you found a way to change the player models.

I'd just suggest that you should rework the PerformSwitch function a bit, so it stays mod independent. The way it is now, if you run the plugin on other mods, it will probably crash the clients on changing if you switch them to whatever TEAM_2 is (on TF2, I think it's red), because you set them a model that does not exist. I don't know what will happen then.

Fixing this is very easy, you just have to move your model changing code into the if clause that checks if the cstrike extension is available, and make it run only if the ext was found.

Greetings
__________________
Ich hab nie behauptet dass ich kein Genie bin!
Mumble-Django: A web interface for Mumble
MistaGee is offline
Send a message via ICQ to MistaGee
Snake60
Senior Member
Join Date: Jul 2008
Location: Russia, Pskov
Old 04-01-2009 , 06:41   Re: TeamSwitch
Reply With Quote #128

Hi MistaGee!
Glad to see you here
OK, I understand you. Thanks for your opinion. Will try to do this now
May be you can help me in to do list???

ADD: Update plugin!!! Can anybody test this version of plugin in other mods??? In CS:S seems it works good.

Last edited by Snake60; 04-01-2009 at 07:37.
Snake60 is offline
Send a message via ICQ to Snake60 Send a message via MSN to Snake60 Send a message via Skype™ to Snake60
jackennils
New Member
Join Date: Mar 2009
Old 04-01-2009 , 16:02   Re: TeamSwitch
Reply With Quote #129

Hey there.

I would love to use this, but it doesn't work with Insurgency.
The menu is displayed but pressing a number doesn't do anything.
Any chance to make it compatible?
jackennils is offline
bobbobagan
SourceMod Donor
Join Date: May 2007
Location: New Zealand
Old 04-09-2009 , 10:06   Re: TeamSwitch
Reply With Quote #130

I was playing aliased, and for some reason when I tried to swap myself with my unaliased name (forgetting I was aliased) it said it could not find me, and swapped another random player instead.

See the screenshot:


Can you please fix this bug!
__________________

Last edited by bobbobagan; 04-09-2009 at 10:11.
bobbobagan is offline
Send a message via Skype™ to bobbobagan
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:23.


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