Bravo List

Bravo List (http://www.bvlist.com/index.php)
-   TBDev (http://www.bvlist.com/forumdisplay.php?f=20)
-   -   Betting system (http://www.bvlist.com/showthread.php?t=698)

LuddeSnutte 24th July 2008 02:23

Betting system
 
Hi, I have search in hour but I can not fint a betting system to tbdev..

I will bet on sports, ex: football ect.

Are it someone know where I can find that?

//LuddeSnutte

ohm2525 6th August 2008 08:53

I want betting for TS. :shock:

Muikku 12th August 2008 19:57

I want betting game too TS 5.4.1 :sos:

Marco 7th June 2010 11:09

hello
 
here we go

i wish to mention it's not my work it's a tbdeved version translated in hungarian by angelo and with bibicu help :) so if you need another language you have to translate

1step SQL
Code:

DROP TABLE IF EXISTS `bet`;

CREATE TABLE `bet` (

`id` int(10) unsigned NOT NULL auto_increment,

`name` varchar(50) NOT NULL default '',

`active` tinyint(1) unsigned NOT NULL default '0',

PRIMARY KEY (`id`)

) TYPE=MyISAM AUTO_INCREMENT=1 ;



--

-- Dumping data for table `bet`

--





-- --------------------------------------------------------



--

-- Table structure for table `bet_winns`

--



DROP TABLE IF EXISTS `bet_winns`;

CREATE TABLE `bet_winns` (

`id` int(10) unsigned NOT NULL auto_increment,

`betid` int(10) unsigned NOT NULL default '0',

`choice` tinyint(2) default NULL,

PRIMARY KEY (`id`),

KEY `betid` (`betid`),

KEY `choice` (`choice`)

) TYPE=MyISAM AUTO_INCREMENT=1 ;



--

-- Dumping data for table `bet_winns`

--





-- --------------------------------------------------------



--

-- Table structure for table `betchoices`

--



DROP TABLE IF EXISTS `betchoices`;

CREATE TABLE `betchoices` (

`id` int(10) unsigned NOT NULL auto_increment,

`betid` int(10) unsigned NOT NULL default '0',

`name` varchar(50) NOT NULL default '',

`active` tinyint(1) unsigned NOT NULL default '0',

`choice1` varchar(40) default NULL,

`choice2` varchar(40) default NULL,

`choice3` varchar(40) default NULL,

`choice4` varchar(40) default NULL,

`choice5` varchar(40) default NULL,

`choice6` varchar(40) default NULL,

`choice7` varchar(40) default NULL,

`choice8` varchar(40) default NULL,

`choice9` varchar(40) default NULL,

`choice10` varchar(40) default NULL,

`payout1` decimal(2,1) default NULL,

`payout2` decimal(2,1) default NULL,

`payout3` decimal(2,1) default NULL,

`payout4` decimal(2,1) default NULL,

`payout5` decimal(2,1) default NULL,

`payout6` decimal(2,1) default NULL,

`payout7` decimal(2,1) default NULL,

`payout8` decimal(2,1) default NULL,

`payout9` decimal(2,1) default NULL,

`payout10` decimal(2,1) default NULL,

PRIMARY KEY (`id`),

KEY `betid` (`betid`)

) TYPE=MyISAM AUTO_INCREMENT=1 ;



--

-- Dumping data for table `betchoices`

--





-- --------------------------------------------------------



--

-- Table structure for table `bets`

--



DROP TABLE IF EXISTS `bets`;

CREATE TABLE `bets` (

`id` int(10) unsigned NOT NULL auto_increment,

`userid` int(10) unsigned NOT NULL default '0',

`betid` int(10) unsigned NOT NULL default '0',

`choice` tinyint(2) unsigned NOT NULL default '0',

`bet` bigint(13) unsigned NOT NULL default '0',

`paid` tinyint(1) unsigned NOT NULL default '0',

PRIMARY KEY (`id`),

KEY `userid` (`userid`),

KEY `betid` (`betid`),

KEY `choice` (`choice`)

) TYPE=MyISAM AUTO_INCREMENT=1 ;



--

-- Dumping data for table `bets`

--

create a file named betting.php
[code]
require 'global.php';

dbconn();

loggedinorreturn();
$action = $_GET["action"];
if ($action == "placebet") {
$betid = 0 + $_POST["bcid"];
if ($betid == "")
stderr("Error", "Oh Nice One You Fucked Up.");
$i = 1;
while ($i < 11) {
$bi = "amount" . $i;
if ($_POST[$bi] != "") {
$bis = $bi;
$amount = 0 + $_POST[$bi];
}
$i++;
}
$amount = round($amount * 1048576);
$maxamount = round($CURUSER['uploaded'] / 10);
if ($amount > $maxamount)
stderr("Hiba!", "Nincs fedezete a fogad

mmisu120000 9th June 2010 22:13

Yes! it's working!

But, the only thing is that I don't speak hungarian ... anyone that can translate it in english?

Good job, marco !

wMan 10th June 2010 09:10

you have
 
you need to add all lag files to this which are missing

Marco 10th June 2010 09:48

:D
 
2 Attachment(s)
:friend:here the english php attached...please be kind ...for my english lang :)
maybe somebody transfer this topic to solved mods on TS


btw. this mod have 2 issues.... can't close the bets when the match is started.... and it's not sending automatically PM-s to the winners....

:) good luck

Muikku 14th June 2010 09:26

thanx the mod but sql file not wor for me whats wrog whit that?

phpmyadmin gives that error
Code:

1064: You have an error in your SQL syntax;  check the manual that corresponds to your MySQL server version for the  right syntax to use near ';  CREATE TABLE `bet` (  `id` int(10) unsigned NOT NULL auto_increment,  `' at line 1


can someone do the sql file works in tsse 5.4.1 version?

Thanx!

Marco 14th June 2010 09:34

i suppose it's different phpmyadmin and the pronnounce is the trouble...take a look on your install sql what is different from this

if you send me your sql (fresh one) not your db i will figure out

Muikku 14th June 2010 22:26

Quote:

Originally Posted by Marco (Post 23507)
i suppose it's different phpmyadmin and the pronnounce is the trouble...take a look on your install sql what is different from this

if you send me your sql (fresh one) not your db i will figure out



i have this sql code what is your post in up and that not work for me

and my MySQL Version 5.0.32-Debian_7

Now i get this error
SQL ERROR Table 'TSSE.bet' doesn't exist in __FILE, line 189 how fix


All times are GMT +2. The time now is 08:11.

Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.