AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   SourceBans / SourceBans++ (https://forums.alliedmods.net/forumdisplay.php?f=152)
-   -   Release SourceBans++ (v1.6.4) [Updated: 2021-10-06] (https://forums.alliedmods.net/showthread.php?t=263735)

September 03-11-2016 07:55

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
Where can I find the themes for this sourcebans? ;)

DarkDeviL 03-11-2016 08:28

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
Quote:

Originally Posted by durangod (Post 2401498)
@arne1288 lol hey the order placed was to remove the link, the rest is up to god :)


ok ok you can do this...

[...]

Or it is possible to provide a real patch, adding the possibility of enabling/disabling Steam OpenID in the settings, which really checks whether or not the option is enabled before showing (and allowing access) through the functions.

durangod 03-11-2016 08:45

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
Oh now you want to get fancy lol... hee hee ok let me see what I can come up with sir :)

Main Fighter 03-11-2016 17:26

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
Okay, so I installed the latest update (1.5.4.2) last night and now the website can't connect to the servers.

http://puu.sh/nDaOU/c0af756508.png

That's what I mean by can't connect.

I have changed nothing besides just updating to 1.5.4.2 I have no idea why it stopped working.
All ports are open I have no firewall in place on the website and the ports 27000 to 27100 are open on the server side both UDP and TCP.

I have complete control over the webserver that I have my website running off so I can put anything in place that I need to, to fix the problem.

Does anyone know whats going on?

EDIT: Okay, I figured it out with the debug stuff... Apparently the webservers IP is banned by the game server. I should be able to figure this out with a quick Google search hopefully.

durangod 03-11-2016 19:33

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
Quote:

Originally Posted by September (Post 2401502)
Where can I find the themes for this sourcebans? ;)

I think they may be hard to find, i have not found any and am pretty much making my own. The one gentlemen that used to make the closed his site down and does not do that anymore. So you may have to get someone to do it for you if you don't know how to do it.

As i tip here - take one of the current theme folders and copy it to your pc, rename the folder to something else ie: mytheme, then change the info inside the theme.conf.php so you dont have two with the same name, the name is stored inside there.

And then upload it to your themes folder and play around with the css. You might do fine just changing colors in the css.

To view your changes just change to that theme in admin and clear your cache. You can always go back to your real "production" theme afterwards.

Hope that helps

durangod 03-11-2016 20:15

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
2 Attachment(s)
Ok folks here is the Mod for Steam Login:

Name: Steam Login Option Mod

What does it do: It allows admin to select weather to show or not to show the steam login link on the login form. This is done by means of selection the option in admin panel - web panel settings - features. If the item is checked the steam signon will show, if it is not checked it will not. And the steam page has been locked down from direct public execution only while the selection is off.

See the image attached to show you the location of the new item setting.

Be sure you always use ONLY either notepad, programmers notepad, or notepad++ to edit code files. Normal word processing software's have hidden codes which will mess up your code files.

Of course the dev of this plugin is welcome to add this to the core production release if they choose.
I have included the zip file with the files you need. Please refer to the files for changes even though i will go over this below in detail. Also remember that all mods will be removed whenever you update the main plugin and the mods will have to be replaced.

Ok lets go:

Lets do the template files first.

Open themes/<theme name>/page_admin_settings_features.tpl

Code:

<!-- added for steam login option mod -->
  <tr>
  <td valign="top"><div class="rowdesc">{help_icon title="Enable Steam Login" message="Check this box, if you want to enable the Steam login button on the login form."}Enable Steam Login</div></td>
      <td>
      <div align="left">
          <input type="checkbox" name="enable_steamlogin" id="enable_steamlogin" />
      </div>
      <div id="enable_steamlogin.msg" class="badentry"></div>
      </td>
  </tr>
<!-- end steam login option mod -->

open themes/<theme_name>/page_login.tpl

This is for the default theme - the others original codes are a bit different so watch carefully and do not replace those with this new code, it will require you to mod it a bit or use part of the old code.

old code
Code:

<center><a href="steamopenid.php"><img src="images/steamlogin.png"></a></center>
new code

Code:

-{if $steamlogin_show == 1}-
<center><a href="steamopenid.php"><img src="images/steamlogin.png"></a></center>
-{/if}-

open pages/admin.settings.php
3 changes in this file

PHP Code:

//added for steam login option mod

   
$steamloginopt = (isset($_POST['enable_steamlogin']) && $_POST['enable_steamlogin'] == "on" 0);

// end steam login option mod 

you dont have to copy the //NEW CODE that is just for your reference
however do include the //modified comment above your change

PHP Code:

//modified for steam login option mod
//ORIGINAL CODE
(" . (int)$adminrehash . "'config.enableadminrehashing')");

//NEW CODE 
(" 
. (int)$adminrehash ", 'config.enableadminrehashing'),
(" 
. (int)$steamloginopt ", 'config.enablesteamlogin')"); 

now all the way toward the bottom of the file is this last addition

PHP Code:


/* added for steam login option mod */
$('enable_steamlogin').checked = <?php echo $GLOBALS['config']['config.enablesteamlogin']?>;
/* end steam login option mod */



Open pages/page.login.php

Right BEFORE This Code:

PHP Code:


$theme
->assign('redir'"DoLogin('".(isset($_SESSION['q'])?$_SESSION['q']:'')."');"); 

Add this NEW CODE:

PHP Code:


//added for steam login option mod

$steam_conf_value get_steamenabled_conf($confvalue);

$theme->assign('steamlogin_show',  $steam_conf_value);

//end steam login option mod 



open includes/user-functions.php


PHP Code:


/**
 * added for the steam login option mod
 * checks the value of the config setting
 * called by  steamopenid.php 
 * called by pages/pages.login.php
 * @param int 1 or 0
 * @return int 
 */
function get_steamenabled_conf($value)
{
 
$settingvalue "config.enablesteamlogin";
 
$query $GLOBALS['db']->GetRow("SELECT `value` FROM `" DB_PREFIX "_settings` WHERE `setting` = '$settingvalue'");
 
$value intval($query['value']);
return 
$value;


open steamopenid.php
two additions in this file

PHP Code:

// added for steam login option mod
include_once('includes/user-functions.php');

$steam_conf_value get_steamenabled_conf($confvalue);

if(
$steam_conf_value 0)
{
//end steam login option mod 

all the way to the bottom of the file

PHP Code:

//added for steam login option mod
//else if the steam config is 0
}else{
       
header("location: ./");
       exit;
      }
//close else 
//end steam login option mod 

Database

manual insert into sb_settings
setting = config.enablesteamlogin
value = 1

or run this sql (fill in your db info in the sql

INSERT INTO `YOURDBPREFIX_YOURDBNAME`.`sb_settings` (`setting`, `value`) VALUES ('config.enablesteamlogin', '1');

refresh your cache from admin and your all set, try it out and let me know if you have any issues.

Thanks dave

attached files

features_ss.jpg (shows the new feature item in settings)

steam_signon_mod.zip (modified files)

Coyote570 03-13-2016 12:25

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
Hi, do you have an issue for this error ?

[+] SourceBans "Error Connecting()" Debug starting for server 5.39.101.173:27015

[+] Trying to establish UDP connection
[+] UDP connection successfull!
[+] Trying to write to the socket
[+] Successfully requested server info. (That doesn't mean anything on an UDP stream.) Reading...
[-] Error getting server info. Can't read from UDP stream. Port is possibly blocked.

[+] Trying to establish TCP connection
[+] TCP connection successfull!
[+] Trying to write to TCP socket and authenticate via rcon
[+] Successfully sent authentication request. Reading...
[+] Got an response!
[+] Password correct!

durangod 03-13-2016 14:33

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
@arne1288 its ok arne, I don't require a thank you or anything.

@Coytote570 Get the port from your game server and make sure that UDP port is open on both the gameserver and the webserver and it will connect. Also remember to add your game server ip to the remote MySQL option in your cpanel (if you use cpanel).

Coyote570 03-14-2016 18:07

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
@durangod ok thx, but, where am I supposed to open the port ? (I don't use cpanel)

durangod 03-14-2016 18:29

Re: [RELEASE] SourceBans++ (v1.5.4.2) [Updated: 2016-03-09]
 
@Coyote570

There are quite a few videos and text help results on google if you have a windows machine or a Linux machine. I dont run my own dedicated server, i use a host company for the game server and i use cpanel for the web side.

Just google "how to open ports" and i am sure you will find what you need.


All times are GMT -4. The time now is 07:51.

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