Riiicardoo Posted October 13, 2011 Author Share Posted October 13, 2011 **Server~Side**In **frmServer** in Tab **Players** crate 1 **commandbutton** called:> Name: mnumMute> Caption: Mute2 clicks and add:``` Dim Name As String Name = frmServer.lvwInfo.SelectedItem.SubItems(3) If Not Name = "Not Playing" Then Call ToggleMute(FindPlayer(Name)) End If```After the **modDatabase** look for:```Public Sub LoadOptions() Options.Game_Name = GetVar(App.Path & "\data\options.ini", "OPTIONS", "Game_Name") Options.Port = GetVar(App.Path & "\data\options.ini", "OPTIONS", "Port") Options.MOTD = GetVar(App.Path & "\data\options.ini", "OPTIONS", "MOTD") Options.Website = GetVar(App.Path & "\data\options.ini", "OPTIONS", "Website")End Sub```Below add:```Public Sub ToggleMute(ByVal index As Long) ' left out for rte9 If index <= 0 Or index > MAX_PLAYERS Then Exit Sub 'Toggle player mute If Player(index).isMuted = 1 Then Player(index).isMuted = 0 ' Let them know PlayerMsg index, "You were Discilenciado and can already speak of change", BrightGreen TextAdd GetPlayerName(index) & " Você foi Discilenciado." Else Player(index).isMuted = 1 ' Let them know PlayerMsg index, "You have been silenced and can not talk about change", BrightRed TextAdd GetPlayerName(index) & " Você foi Silenciado." End If ' Save the player SavePlayer indexEnd Sub```look for:```Private Sub HandleBroadcastMsg(ByVal index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long)```beneath:```Msg = Buffer.ReadString```add:```If Player(index).isMuted Then PlayerMsg index, You have been silenced and can not talk about change", BrightRed Exit Sub End If```look for:```' Position MAP As Long x As Byte y As Byte Dir As Byte```add below:```'muteisMuted As Byte```Credits: Robin Link to comment Share on other sites More sharing options...
Domino_ Posted October 13, 2011 Share Posted October 13, 2011 Looks nice, you'r riping them from CS:DE? :D Link to comment Share on other sites More sharing options...
Riiicardoo Posted October 13, 2011 Author Share Posted October 13, 2011 Yes, but I was not, was my friend Link to comment Share on other sites More sharing options...
erkro1 Posted October 13, 2011 Share Posted October 13, 2011 @Riiicardoo:> Yes, but I was not, was my friendSo, you posted it Link to comment Share on other sites More sharing options...
PVJsquad Posted February 5, 2012 Share Posted February 5, 2012 why The player Not muted OnlyThere are only written warningscan stiill speak Link to comment Share on other sites More sharing options...
Scott Posted February 5, 2012 Share Posted February 5, 2012 @GoldSide:> why The player Not muted Only> There are only written warnings> can stiill speak@Riiicardoo:> ```> If Player(index).isMuted Then> PlayerMsg index, You have been silenced and can not talk about change", BrightRed> Exit Sub <-------HERE> End If> ```You would not be able to talk, the line marked HERE is what causes this, it stops everything after it from running. So with this it gets the msg string, but never uses it. Link to comment Share on other sites More sharing options...
PVJsquad Posted February 6, 2012 Share Posted February 6, 2012 @Scott:> You would not be able to talk, the line marked HERE is what causes this, it stops everything after it from running. So with this it gets the msg string, but never uses it.so how do you get the player to mute Link to comment Share on other sites More sharing options...
Scott Posted February 6, 2012 Share Posted February 6, 2012 By cutting of the sub before it displays your message really simple stuff. Link to comment Share on other sites More sharing options...
Whackeddie99 Posted February 6, 2012 Share Posted February 6, 2012 doesn't mute for map messages but that's an easy fix. Link to comment Share on other sites More sharing options...
SholT Posted March 16, 2012 Share Posted March 16, 2012 del Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now