Shakes & Fidget Private - Full Script (Tulyita)

06/19/2014 19:29 TheCry#736
Quote:
Originally Posted by SF SMASH View Post
[Only registered and activated users can see links. Click Here To Register...]

NEW SCRIPT FOR TOWER FIGHT! GET + 300 STATS AND MORE HP IN FIGHT.
Please don't hate the script in alpha :)

Next update for event OCTOBERFEST!

sorry for my bad eng

Smash :)
Never mind difficult.... I think that everyone already a long time ago popped to it.... It would be a feat if you finished this script to the armour :) think above it if you can ;)
06/19/2014 19:49 SF SMASH#737
It will be possible armor could already be tonight but those entries in the db, etc.
06/19/2014 20:05 TheCry#738
Quote:
Originally Posted by SF SMASH View Post
It will be possible armor could already be tonight but those entries in the db, etc.
Good luck ;)
06/19/2014 20:21 SF SMASH#739
MrCry armor I corrected so that it no longer works normally but if you do not want to make it in the piece rotated personnel such as armor you buy a 1753 case from the magic shop you get 0 armor so I'll have to have a case of magic shop armor but I think it is one
06/19/2014 20:23 MaYeX159#740
Quote:
Originally Posted by SF SMASH View Post
MrCry armor I corrected so that it no longer works normally but if you do not want to make it in the piece rotated personnel such as armor you buy a 1753 case from the magic shop you get 0 armor so I'll have to have a case of čaroobchodu armor but I think it is one
XXX my bad :D I thougt that Cry is czech but he is polish sorry -EDITED
06/19/2014 20:26 SF SMASH#741
Quote:
Originally Posted by MaYeX159 View Post
XXX my bad :D I thougt that Cry is czech but he is polish sorry -EDITED
:D


Armor works 90% :)
OCTOBERFEST fixed
06/19/2014 21:02 TheCry#742
Quote:
Originally Posted by SF SMASH View Post
:D

[Only registered and activated users can see links. Click Here To Register...]

Armor works 90% :)
OCTOBERFEST fixed
Good Job! Can u give script?
06/19/2014 21:05 UND3RW0RLD#743
Quote:
Originally Posted by SF SMASH View Post
:D

[Only registered and activated users can see links. Click Here To Register...]

Armor works 90% :)
OCTOBERFEST fixed
Share the octoberfest-code?
06/19/2014 21:06 TheCry#744
Quote:
Originally Posted by ǝnd1ǝss-ɯonǝʎ View Post
Share the octoberfest-code?
And armour code if he want :)
06/19/2014 21:43 SF SMASH#745
I will not lie Octoberfest going to do simply overwrite Client cfg 2 and 3 line to its texture and switch eg for Christmas event eventually. event_ovl_6, create a surplus in request :)

and the script is public for all 01.July.2014
06/20/2014 19:47 UND3RW0RLD#746
Avoid guildpushing

Code:
--
-- Tabellenstruktur für Tabelle `game_settings`
--

CREATE TABLE IF NOT EXISTS `game_settings` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `setting` varchar(255) NOT NULL,
  `value` varchar(255) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=31 ;

--
-- Daten für Tabelle `game_settings`
--

INSERT INTO `game_settings` (`id`, `setting`, `value`) VALUES
(30, 'GUILD_S_MINLEVEL', '100');
Controlpage
PHP Code:
<?php

    
// Project: S&F Teamcontroll-Center
    // Author: Coder
    // Date: 20.06.
    // You are allowed to modify and/or redistribute any part of this

require_once("backend/main.php");
dbconn();
loggedinorreturn();

stdhead("minlevel");

//check for permission
if(get_perm() < UC_ADMIN)
{
    echo 
"GTFO!";
    
stdfoot();
    die();
}

// request
if(isset($_POST["level"]))
{
    
$nval sqlesc($_POST["level"]);
    
mysql_query("UPDATE game_settings SET value = " $nval " WHERE setting = 'GUILD_S_MINLEVEL'");
    echo 
"Success and refresh";
?>
    <meta http-equiv="refresh" content="0; URL=<?=$_SERVER["PHP_SELF"?>">
<?php    
}
else
{
    
// setting level
    
$sql "SELECT value FROM game_settings WHERE setting = 'GUILD_S_MINLEVEL' LIMIT 1";
    
$qry mysql_query($sql);
    
$arr mysql_fetch_array($qry);
    
$minlevel $arr["value"];



?>
    <form action="<?=$_SERVER["PHP_SELF"?>" method="post" enctype="multipart/form-data" target="_self">
    <table align="left" border="0" cellpadding="4" cellspacing="1" class="tableinborder" summary="none" width="300px">
        <tr>
            <td align="left" class="tablecat">Mindestlevel for guildspending</td>
        </tr>
        <tr>
            <td align="left" class="tableb"><b>Level:</b> <input type="text" name="level" size="4" value="<?=$minlevel?>"> (press enter)</td>
        </tr>
    </table>
    </form>
<?php
}
stdfoot();
?>
go to settings.php
add
PHP Code:
<br><br><a href="guildminlevel.php">Mindestlevel for guildspending</a></td
New act donate
PHP Code:
    case $ACT_GUILD_DONATE :
        
        
$in explode ';'$action_extra );
        
        
$donation = array (
                
'silver' => 0,
                
'mushroom' => 
        
);
        
        if (
$in [0] == 1)
        {
            
$donation ['silver'] = ( int ) $in [1];
        }
        else
        {
            
$donation ['mushroom'] = ( int ) $in [1];
//            $ret = array($ERR_GUILD_MUSH_FREE);
//            break;
        
}

        
// Avoid Pushaccounts 20.06. ACP-Integration
        
$qry $GLOBALS ['db']->prepare "SELECT value FROM game_settings WHERE setting = 'GUILD_S_MINLEVEL' LIMIT 1" );
        
$qry->execute ();
        
$res $qry->fetchAll PDO::FETCH_ASSOC );

        
// DB -> Var 
        
$minlevel $res [0] ['value'];


        
// get gold and mush of donor
        // +level for levelcheck 20.06.
        // user_data.lvl AS level
        
$qry $db->prepare "SELECT user_data.lvl AS level, user_data.silver AS silver, user_data.mushroom AS mushroom,  
                user_data.guild_id, guilds.silver AS gsilver, guilds.mushroom AS gmushroom
                FROM user_data  
                LEFT JOIN guilds ON user_data.guild_id = guilds.guild_id
                WHERE ssid = :ssid" 
);
        
$qry->bindParam ':ssid'$SSID );
        
$qry->execute ();

        
$db_data $qry->fetchAll ();
        
$db_data $db_data [0];

        
// Jessis Guildcheat Fix
        
if($donation ['silver'] <= 0)
            
$donation ['silver'] = 0;

        if(
$donation ['mushroom'] <= 0)
            
$donation ['mushroom'] = 0;
        
// end of GC

        // if not enought gold
        
if ($db_data ['silver'] < $donation ['silver'])
        {
            
$ret = array (
                    
$ERR_TOO_EXPENSIVE 
            
);
            break;
        }

        
// Avoid Pushaccounts 20.06.
        
if ($db_data ['level'] < $minlevel)
        {
            
$ret = array (
                    
$ERR_MSG_LEVEL_TOO_LOW 
                    
            
);
            break;
        }
        
        
// if not enought silver
        
if ($db_data ['mushroom'] < $donation ['mushroom']) {
            
$ret = array (
                    
$ERR_GUILD_LACK_MUSH 
            
);
            break;
        }
        
        
// Avoid Pushaccounts 20.06.
        
if($minlevel <= $db_data ['level'])
        {
            
// transfer gold && mushroom
            
$db_data ['silver'] = $db_data ['silver'] - $donation ['silver'];
            
$db_data ['mushroom'] = $db_data ['mushroom'] - $donation ['mushroom'];
            
$db_data ['gsilver'] = $db_data ['gsilver'] + $donation ['silver'];
            
$db_data ['gmushroom'] = $db_data ['gmushroom'] + $donation ['mushroom'];
            
            
// update database
            
$qry $db->prepare "UPDATE user_data  
                    SET silver = :silver, 
                    mushroom = :shroom,
                    g_silverspent = g_silverspent + :dsilver,
                    g_mushroomspent = g_mushroomspent + :dmush 
                    WHERE ssid = :ssid" 
);
            
$qry->bindParam ':ssid'$SSID );
            
$qry->bindParam ':silver'$db_data ['silver'] );
            
$qry->bindParam ':shroom'$db_data ['mushroom'] );
            
$qry->bindParam ':dsilver'$donation ['silver'] );
            
$qry->bindParam ':dmush'$donation ['mushroom'] );
            
$qry->execute ();
            
            
$qry $db->prepare "UPDATE guilds SET  
                    silver = :silver, 
                    mushroom = :shroom 
                    WHERE guild_id = :gid" 
);
            
$qry->bindParam ':gid'$db_data ['guild_id'] );
            
$qry->bindParam ':silver'$db_data ['gsilver'] );
            
$qry->bindParam ':shroom'$db_data ['gmushroom'] );
            
$qry->execute ();
        }
        
// var_dump($qry -> errorInfo());
        
        // response
        
loadDefaultData ();
        
        
$ret [0] = $RESP_GUILD_DONATE_SUCCESS $ret [0];
        
        break; 
Go to languagefile and change the displayed error

[Only registered and activated users can see links. Click Here To Register...]

[Only registered and activated users can see links. Click Here To Register...]
06/20/2014 20:46 jkoby#747
@ǝnd1ǝss-ɯonǝʎ , you rock. thanks alot!


Guys did anyone knows a way to add custom language lines to client. I add them in sfgame_<lang>.txt but how to display them as i like ?
06/20/2014 21:36 Crasim#748
Quote:
Originally Posted by jkoby View Post
@ǝnd1ǝss-ɯonǝʎ , you rock. thanks alot!


Guys did anyone knows a way to add custom language lines to client. I add them in sfgame_<lang>.txt but how to display them as i like ?
edit this line on client_cfg.php

46 ar/cs/da/de/en/es/fr/el/hu/it/ja/nl/pl/pt/pt-br/ru/sv/tr
47 arabic/czech/danish/german/english/spanish/french/greek/hungarian/italian/japanese/dutch/polish/portuguese/brazilian portuguese/russian/swedish/turkish

and add flags on /res/sfgame/res/gfx/if/flags/flag_<yourlang>.png
06/20/2014 23:07 jkoby#749
Thanks for this Crasim, but actualy my question was how to put new lines in the sfgame_en.txt and display them. Since i've made changes to the game like no more arena attacks on +/- 10 levels diff, 5 attacks per day of player, no more attacks on [GA] account and etc and want to $ret custom language line instead of using existing one. Is it possible actualy ?
06/20/2014 23:51 Crasim#750
Quote:
Originally Posted by jkoby View Post
Thanks for this Crasim, but actualy my question was how to put new lines in the sfgame_en.txt and display them. Since i've made changes to the game like no more arena attacks on +/- 10 levels diff, 5 attacks per day of player, no more attacks on [GA] account and etc and want to $ret custom language line instead of using existing one. Is it possible actualy ?
I've also tried to add strings ban, but from what I have been able to "verify" you have to change the swf game