PDA

View Full Version : Major Additions - Casino (w/ 10 player poker)


Pages : [1] 2 3 4 5 6 7 8 9 10 11 12 13 14 15

Andrew Green
09-29-2007, 10:00 PM
The Gameroom is the follow up to this, and expands on its features. This mod will no longer be supported, Gameroom is here: https://vborg.vbsupport.ru/showthread.php?t=219483

This is a casino addition for vBulletin, so far containing video poker, blackjack, Slots, a lottery, Let 'em Ride, Roulette and a betting pool.

It can use it's own cash as well as cash fields from other products for easy integration. Cash bonuses are also awarded for various actions (posting, starting threads, etc.), you can alter the bonus values through the admincp.

Each of the 10 games can be turned on or off through the control panel, and the casino can be restricted by user group.

I'd consider this a test run, everything should work, but some of the template's and all of the phrasing are not done yet.

Screenshots are attached.

If you want to see a demo, it's live at http://vbgaming.org, it does require registration though as it needs a userid to attach your money too ;) Bug reports and requests can also be posted there, and will probably have less chance of getting buried in this rather massive thread. If you are having a problem, please look there. If it is one that others have been having, there will likely be a solution there (as well as in this thread, just harder to find here)

v 0.90 (Jan 6)
- Fixed a bug in lottery odds calculation that was casuing problems with the jackpot.
- Completed Phrasing of all games & admincp
- Removed card flicker some people experienced in Texas Hold'em
- Removed unused table limit setting from Video Poker settings
- Handled a DB error that occasionally came out of the slots game
- Sports Pool groups are now edited through the game, not the admincp
- Blackjack: Dealer checks for blackjack on A or 10
- Blackjack: Added Five card charlie rule
- Texas Hold'em: poker mod groups can now use the command "/kick username" to kick people out of the game. If a hand is in progress it counts as a forced fold, not returning their share of the pot.
- Blackjack - Fixed bug on bet amount when splitting more then once on a hand

v 0.91 (Jan 13)
- Added missing field for holdem mod groups to settings table
- Removed 0.90 test code of drawin same numbers in lottery
- Piped all the ajax files through casino.php, this should solve some of the conflicts people where having (ex. mkportal)
- Added missing link to add / edit groups in sports pool
- Fixed extra \'s in chatbox some users where getting
- Added a reset cash button in the ACP
- Fixed a bug where the blackjack_dealt table wasn't getting cleared properly
- Fixed "Most Lost" stat calculation


v 0.92 (Feb 18)
- Fixed Default Cash not saving
- Texas Hold'em no longer shows hand after folding
- Texas Hold'em buttons should not reappear after clicking if a request was in progress when they where clicked
- Fixed some of the reinstall issues people have been having

This is pretty minor, working on some major changes to the Texas Hold'em game that are taking longer then I planned due to other things coming up.

Known issues:
- The same player attempting to play more then one instance of the same game at the same time will cause errors.

To update overwrite all of the old files and import the product, revert any modified (casino) templates and don't forget the files in other folders ;) Also some of the images have changed, those need uploaded again. (as well as the includes and admincp files) You DO NOT need to uninstall the previous version to upgrade, this will cause problems. Just overwrite existing files and import the product again, allowing overwrite.

**Make sure you overwrite ALL existing files and revert ALL casino templates**

gbml4u
09-30-2007, 10:23 PM
first installed. thx u so much

iogames
09-30-2007, 10:28 PM
Wooow! LIK-IT! :D
but I will wait for 0.2 version :P

have you seen Xuqa.net? they have poker rooms... how can this be done?

Men this smell as a MotM ;)

Andrew Green
09-30-2007, 10:36 PM
Wooow! LIK-IT! :D
but I will wait for 0.2 version :P

have you seen Xuqa.net? they have poker rooms... how can this be done?

Men this smell as a MotM ;)

I plan on getting a multiplayer poker game in there, but don't ask for a timeline ;)

Masiello
09-30-2007, 10:41 PM
Oh great! waiting for a stable version!
Multiplayer is awesome!

SuperTaz
09-30-2007, 11:08 PM
I will wait for a more stable version to add to my gaming site.

iogames
09-30-2007, 11:08 PM
I plan on getting a multiplayer poker game in there, but don't ask for a timeline ;)

I won't ask if you tell me when :P

Kaleem
09-30-2007, 11:58 PM
clicking install to get future updates will watch it :)

stangger5
10-01-2007, 12:56 AM
Has anyone got this install ??

I get the first page working fine but when you try to play a game,,,I get red X`s and a box that just says loading...

Andrew Green
10-01-2007, 01:27 AM
Do you have javascript enabled?

and does it happen on all 4?

stangger5
10-01-2007, 01:33 AM
Yes for both...

Andrew Green
10-01-2007, 01:37 AM
Yes for both...

Do other AJAX features work for you?

stangger5
10-01-2007, 01:43 AM
Yes..

Andrew Green
10-01-2007, 01:58 AM
Something is conflicting with the code amber banner. Sticking that on my site broke it there as well...

stangger5
10-01-2007, 02:04 AM
I just took everything out of the footer template...It didnt help...

If you look on thefulcrumpoint.org and the disturbed_x skin,,you`ll see what i`m talking about...
I have it set for non registered members can see...

stangger5
10-01-2007, 02:08 AM
The first page is fine...click on Video Poker and see what happens...Look at the links in the Nav bar after that....it puts casino in front of everything...

Andrew Green
10-01-2007, 02:13 AM
I just took everything out of the footer template...It didnt help...

If you look on thefulcrumpoint.org and the disturbed_x skin,,you`ll see what i`m talking about...
I have it set for non registered members can see...

Skin looks like it is the problem, you got header info going in twice. On line 489 of the source you got this:


<html dir="ltr" lang="en">
<head>
<title>Homepage </title>


and it starts over again with the header info.

stangger5
10-01-2007, 02:23 AM
I`m trying it on anther skin without anything in the footer...Still get the same thing..
I`ve tried disabling different plugins hopeing it was one of them,,no help yet..

kylek
10-01-2007, 03:13 AM
Just installed to 3.6.8 and set for vbcredits. The main casino.php page shows but when you click on a game it just says loading.

QsKGlobal.com
10-01-2007, 03:15 AM
I'm very interested in this hack, clicked install, now lets see a stable version!

trackpads
10-01-2007, 03:24 AM
Installed but how comes there is blackjack in the demo screenshots but not in the game?

trackpads
10-01-2007, 03:27 AM
Never mind, I had the other casino installed, now installing this one :)

Andrew Green
10-01-2007, 03:30 AM
Found the problem with it not loading, I have some paths hardcoded into templates that I forgot I changed, vbulletin doesn't really care for having things outside of the main forum folder.

Temporary fix:

in headinclude:

change
<script type="text/javascript" src="clientscript/vbulletin_global.js?v=$vboptions[simpleversion]"></script>
<if condition="$show['popups']"><script type="text/javascript" src="clientscript/vbulletin_menu.js?v=$vboptions[simpleversion]"></script></if>


to:

<script type="text/javascript" src="/forum/clientscript/vbulletin_global.js?v=$vboptions[simpleversion]"></script>
<if condition="$show['popups']"><script type="text/javascript" src="/forum/clientscript/vbulletin_menu.js?v=$vboptions[simpleversion]"></script></if>


replacing "/forum/" with whatever folder your forum is in.

kylek
10-01-2007, 03:45 AM
That fixed it for me, the only thing I cant seem to show is the lottery, playing with the settings right now. Looks good though.

stangger5
10-01-2007, 03:58 AM
My forum and everything is in the root folder...I renamed the index.php file to forum.php..
Theres no forum folder..

Andrew Green
10-01-2007, 04:02 AM
My forum and everything is in the root folder...I renamed the index.php file to forum.php..
Theres no forum folder..


then just add a "/" in front ;)

ex:
src="/clientscript/vbulletin_global.js?v=$vboptions[simpleversion]">

Andrew Green
10-01-2007, 04:03 AM
That fixed it for me, the only thing I cant seem to show is the lottery, playing with the settings right now. Looks good though.

Ok... I know why, I'll stick a fix up tomorrow.

kylek
10-01-2007, 04:20 AM
Ok... I know why, I'll stick a fix up tomorrow.

Other than the lottery problem, this is cool, members are going to love this!!

Where do you change the percentages for the lottery? If you have it set for 3 balls right now it looks like 3/3 gets 50 %, 2/3 gets 50% and 1/3 gets 0

Andrew Green
10-01-2007, 04:25 AM
Other than the lottery problem, this is cool, members are going to love this!!

Where do you change the percentages for the lottery? If you have it set for 3 balls right now it looks like 3/3 gets 50 %, 2/3 gets 50% and 1/3 gets 0

those percentages are misleading, that's not 50 percent of the pot, it also takes odds into account on that. It's more of a internal modification thing to keep the payout balanced that probably shouldn't be shown outside of testing purposes.

The Minimum payout is a better number to look at. But basically you have odds x percent = payout. In the end it should work out to about 100% payout overtime regardless of what numbers you put in for # of balls and range on them.

stangger5
10-01-2007, 04:59 AM
then just add a "/" in front ;)

ex:
src="/clientscript/vbulletin_global.js?v=$vboptions[simpleversion]">



That fixed the loading problem...I still see a few red X`s...

stangger5
10-01-2007, 05:02 AM
I tried to uninstall it so I could try to install it again...See if something got messed up on the install...
When uninstalling...I get a data base error...

Invalid SQL:
ALTER TABLE user DROP 'casino_cash';

MySQL Error : 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 ''casino_cash'' at line 1
Error Number : 1064

HarryBO
10-01-2007, 10:25 AM
Installed but don´t work. I can´t play any game. Only the Loading screen shows up.

...Still waiting 4 a running version...

Andrew Green
10-01-2007, 12:56 PM
Installed but don?t work. I can?t play any game. Only the Loading screen shows up.


...Still waiting 4 a running version...

Did you adjust the "headinclude" as shown in the 1st post?

Andrew Green
10-01-2007, 01:17 PM
Will try to do a update with all things that have come up so far fixed.
- Lottery not loading the first draw
- messing up paths to vb files / images from being in a separate folder
- SQL error on uninstall.

Anyone getting anything else?

bazzup
10-01-2007, 01:35 PM
this looks good andrew cheers

iogames
10-01-2007, 08:38 PM
Will try to do a update with all things that have come up so far fixed.
- Lottery not loading the first draw
- messing up paths to vb files / images from being in a separate folder
- SQL error on uninstall.

Anyone getting anything else?

Kudos! you're heading the right way...:up:

acegames
10-01-2007, 08:46 PM
Looks great , but I will wait for a stable version , hope thats real soon

Andrew Green
10-02-2007, 03:21 AM
0.11 Update should fix all of the problems that have been brought up.

stangger5
10-02-2007, 04:04 AM
Double click on the casino/blackjack.html file....lol....

Andrew Green
10-02-2007, 04:10 AM
Double click on the casino/blackjack.html file....lol....

lol... opps... a debugging secret leaks...

I'll just get that out of there...

stangger5
10-02-2007, 04:12 AM
Still wont let you uninstall:

Invalid SQL:
ALTER TABLE user DROP 'casino_cash';

MySQL Error : 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 ''casino_cash'' at line 1
Error Number : 1064

Andrew Green
10-02-2007, 04:17 AM
Still wont let you uninstall:

Invalid SQL:
ALTER TABLE user DROP 'casino_cash';

MySQL Error : 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 ''casino_cash'' at line 1
Error Number : 1064

old version of that line, did you update first then try and uninstall? If not try that as that line in the uninstall code should be changed, if not you can manually change the uninstall code for the product, first line to:

$query = "ALTER TABLE ". TABLE_PREFIX . "user DROP COLUMN 'casino_cash'";

basically adding "COLUMN" in there.

stangger5
10-02-2007, 06:17 AM
Everything is working great now and on all skins !!!!

Thanks Andrew !!!!

kylek
10-02-2007, 06:33 AM
Just did two fresh installs of Casino 0.11 on two different sites and both went well with no problems. Lottery looks good, able to buy tickets.

Only thing I can see right now is that it names the casino - Innovative Martial Arts Casino. Will have to search to see where it can be changed.

A question - When setting up first draw in Lottery the jackpot had a number already set, I think in one site it was $24320.00 Is this resettable? It would be nice if we could have a set amount to start out with.

A suggestion or two - instead of showing richest users top 10 could it maybe just show the top 10 members who have made the most in the casino? Have it separate from total points (use vbcredits which has option to keep amounts private) as some members do not like others seeing how much they have.

And the possibility of adding a $25 or $50 token for the big spenders. So poker and blackjack would have $1, $5, $10, and $25 or $50.00

stangger5
10-02-2007, 07:35 AM
To edit the Casino name...Look in the casino_index_main template...

kylek,,,We must be thinking a like....I`ve allready add a $25 and $50 token...lol..

acegames
10-02-2007, 09:26 AM
Just installed but now my site wont load due to a database error ???

stangger5
10-02-2007, 09:29 AM
What kind of error ??

If you cant get rid of the error..

Go into your ftp: includes/config.php and put this at the top,, right under <?php

define('DISABLE_HOOKS', true);

acegames
10-02-2007, 09:40 AM
It was just a database error , I restarted my mysql services and its fine now , thankyou

Now im going to try this casino :)

acegames
10-02-2007, 09:53 AM
Working great here :)

How do I set it up to use vcash ?

Andrew Green
10-02-2007, 11:56 AM
as in vbookie_cash?

in the setup change the cash field to "vbookie_cash"

Andrew Green
10-02-2007, 12:02 PM
Only thing I can see right now is that it names the casino - Innovative Martial Arts Casino. Will have to search to see where it can be changed.


I'll track that down and fix it for the next update, thought I'd go all of them.


A question - When setting up first draw in Lottery the jackpot had a number already set, I think in one site it was $24320.00 Is this resettable? It would be nice if we could have a set amount to start out with.


Draw amount is based off of the range and number of balls and price, it's setup to calculate a jackpot that will maintain about 100% win, and increases over time until it's won. I could add a option to manually edit it though.


A suggestion or two - instead of showing richest users top 10 could it maybe just show the top 10 members who have made the most in the casino? Have it separate from total points (use vbcredits which has option to keep amounts private) as some members do not like others seeing how much they have.


Yes, it does track a number of stats that aren't being used for anything yet, so in later versions there should be more available.


And the possibility of adding a $25 or $50 token for the big spenders. So poker and blackjack would have $1, $5, $10, and $25 or $50.00

Yes, it's in the plans, as well as a switch to allow each amount in the admincp.

kiril_cvetkov
10-02-2007, 12:34 PM
When i want to uninstall this modification - i get mysql error :(

Database error in vBulletin 3.6.8:

Invalid SQL:
ALTER TABLE user DROP 'casino_cash';

MySQL Error : 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 ''casino_cash'' at line 1
Error Number : 1064
Date : Tuesday, October 2nd 2007 @ 07:29:01 AM
Script : http://www.bryansrequestsite.com/forum/admincp/plugin.php?do=productkill
Referrer : http://www.bryansrequestsite.com/forum/admincp/plugin.php?do=productdelete&productid=casino&s=
IP Address : 85.30.68.39
Username : kiril_Cvetkov
Classname : vb_database

Can i uninstall this when i disable the hooks
define('DISABLE_HOOKS', true);

Andrew Green
10-02-2007, 12:52 PM
When i want to uninstall this modification - i get mysql error :(


The update to .11 should fix that. You can also manually fix the uninstall code:

Change the uninstall code for the product, first line to:

$query = "ALTER TABLE ". TABLE_PREFIX . "user DROP COLUMN 'casino_cash'";

Adding "COLUMN" in between "DROP" and "'casino_cash'"

acegames
10-02-2007, 01:26 PM
as in vbookie_cash?

in the setup change the cash field to "vbookie_cash"


Perfect thankyou :)

ChU v2
10-02-2007, 02:10 PM
Looks good, I'll be watching this mod for a texas hold em integration and multiplayer will be great.

ArchangelX
10-02-2007, 05:53 PM
Anyway to integrate this with the other casino mod available? Thanks!

And will this work on 3.5? Thanks again!

Andrew Green
10-02-2007, 05:57 PM
Anyway to integrate this with the other casino mod available? Thanks!


I'm not sure which other casino mod you mean, but I imagine that they would have no problem sharing the same cash. In the admincp you can set the name of the cash field to match the one the other casino uses.


And will this work on 3.5? Thanks again!

I see no reason why it shouldn't, but haven't actually tried it.

ArchangelX
10-02-2007, 06:01 PM
Thanks for the quick response!

It's here: https://vborg.vbsupport.ru/showthread.php?t=158139

It's been out for a while now...and has been constantly updated for each new version of VB. One of the oldest hacks, I believe.

I'll try it out...unfortunately, I'll have to change the casino.php file's name. Thanks!

Andrew Green
10-02-2007, 06:03 PM
I'll try it out...unfortunately, I'll have to change the casino.php file's name. Thanks!

Might be trickier then it sounds, all of the links go through "casino.php", so changing it without also changing any reference to it in the templates and files will break it. Which of course would need to be done again with every update...

stangger5
10-02-2007, 06:08 PM
I have them both installed with no problems...

Casino for vBulletin uses casino.php
and
vbcasino uses lottery.php

ArchangelX
10-02-2007, 06:30 PM
Might be trickier then it sounds, all of the links go through "casino.php", so changing it without also changing any reference to it in the templates and files will break it. Which of course would need to be done again with every update...


Shouldn't be too hard with a complete Find/Replace command for all the calls to casino.php.

I already have a lottery system installed, so when I installed the first vBCasino, I had to change all the instances of lottery.php to casino.php. I'll have to do the same here in order to use it.

But great addition! Kudos for the work on it!

Mark.B
10-02-2007, 08:18 PM
This is excellent....

Only thing I've spotted is that all the templates are uncached.

aztecboi2003
10-02-2007, 09:34 PM
Anyway to make this a little easier for novices to install? I haven't tried it but it looks complex.

Mark.B
10-02-2007, 09:34 PM
In template casino_error, the conditional:
<if condition="$nomoneyslot">
should be....
<if condition="$slotnomoney">

Mark.B
10-02-2007, 09:35 PM
Anyway to make this a little easier for novices to install? I haven't tried it but it looks complex.
It isn't...it's as easy as any other modification. Import the product, upload the files and make a couple of easy template edits.

ArchangelX
10-02-2007, 10:38 PM
It was a pretty painless install...really easy. Just import the product. If you already have a cash mod in, you don't even have to edit the templates.

Anyways, I believe there's a bug in the Blackjack program. When you split it...the totals don't come out ahead. As soon as you split, you're refunded 10 (if you do a 10 token)...which is a little weird. Might want to take a look at that again!

Instead of taking away another 10 for the split, it gives you 10.

Mark.B
10-02-2007, 11:02 PM
It would be handy to specify the time of lottery draws...I'm in the UK so the lottery draw seems to be at 3am!

Andrew Green
10-03-2007, 02:40 AM
It would be handy to specify the time of lottery draws...I'm in the UK so the lottery draw seems to be at 3am!

Well, not yet. It's a labelled .11 for a reason, I still have a lot of features I need to add in. SOme small things like that, others fairly big things (other games)


Instead of taking away another 10 for the split, it gives you 10.

Hadn't noticed that, thanks :)

Hornstar
10-03-2007, 07:45 AM
WOW, this is so fantastic, I am going to watch the progress like an eagle, as this is something that I have always wanted

Thanks so much for sharing this with all of us.

+1 for multiplayer :D

wilburshere
10-03-2007, 10:02 AM
i like the sport pool feature awesome

merismus
10-03-2007, 10:53 AM
I installed the mod and when trying to access the casino page in my website i had error messages all the time saying that the page could not be found and so on i tired to find out where the issue is coming form but no way! When i tried to uninstall the Mod i received an DATABASE error message disallowing to uninstall the mod!

Andrew Green
10-03-2007, 12:50 PM
I installed the mod and when trying to access the casino page in my website i had error messages all the time saying that the page could not be found and so on i tired to find out where the issue is coming form but no way! When i tried to uninstall the Mod i received an DATABASE error message disallowing to uninstall the mod!


What where the error messages? Hard to try and fix it for you without something more specific.

stangger5
10-03-2007, 01:04 PM
I installed the mod and when trying to access the casino page in my website i had error messages all the time saying that the page could not be found


Did you upload the casino.php file ??

Theres three folders (admincp,,casino,,includes) and the casino.php to upload...

bhen13
10-03-2007, 02:14 PM
everything works great except for poker... I get this error..

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /casino/vidpok_redeal.php on line 151

Warning: Wrong parameter count for max() in /casino/vidpok_redeal.php on line 187

Warning: Wrong parameter count for min() in /casino/vidpok_redeal.php on line 187

Andrew Green
10-03-2007, 02:23 PM
Can you confirm that the table "casino_vidpok_dealt" exists in your database?

bhen13
10-03-2007, 02:25 PM
I would , but How??:o

Andrew Green
10-03-2007, 02:28 PM
I would , but How??:o

Do you have phpmyadmin? Or any other way to get into your DB directly?

bhen13
10-03-2007, 02:31 PM
yes

Andrew Green
10-03-2007, 02:36 PM
You can use that to check whether or not the table exists, if not or you're still not sure what I meant I can send you a updated copy of the file that won't fix the problem, but should at least be more descriptive on what the problem is :)

bhen13
10-03-2007, 02:39 PM
please and thank you :D

bhen13
10-03-2007, 02:39 PM
what about more games?

Andrew Green
10-03-2007, 02:41 PM
what about more games?


More games are coming, got to get all the issues with these sorted out first ;)

Anyways, I'm sending you something to try out.

bhen13
10-03-2007, 02:47 PM
ok , thanks

Mark.B
10-03-2007, 02:49 PM
The "main" templates start with
<html>
<head>
This should actually be:
$stylevar[htmldoctype]
<html xmlns="http://www.w3.org/1999/xhtml" dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<head>
It seems to cause some issues with styles otherwise.

Devil Woman
10-03-2007, 06:30 PM
This may sound daft but how do I get this to work with vbcredits?

I have searched but can't find the setting to add to make it work with vbcredits.

Any help is greatly appreciated.

Andrew Green
10-03-2007, 06:33 PM
In the admincp you can set the field that it uses for cash. By default this is "casino_credits" but can be changed, just change it to what vbcredits uses. (vbcredits maybe? I don't use it so thats just a guess)

nickster
10-03-2007, 08:22 PM
At the top of my page it says

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /global.php(237) : eval()'d code on line 2

http://keybase.org/forum/casino.php

any help?

Andrew Green
10-03-2007, 08:38 PM
At the top of my page it says

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /global.php(237) : eval()'d code on line 2

http://keybase.org/forum/casino.php

any help?

That's a strange one, I'll register on your site tonight and poke around in it, and see what global.php might be trying to do at that point, My guess is it's conflicting with something else in there.

I see to <body> tags on that page, which should not be happening, so something is going funny somewhere in there.

sandt38
10-03-2007, 10:52 PM
This may sound daft but how do I get this to work with vbcredits?

I have searched but can't find the setting to add to make it work with vbcredits.

Any help is greatly appreciated.

In the admincp you can set the field that it uses for cash. By default this is "casino_credits" but can be changed, just change it to what vbcredits uses. (vbcredits maybe? I don't use it so thats just a guess)

Should just be "credits" actually, not vBCredits ;)

I edited this on my board and it worked great

sandt38
10-03-2007, 11:10 PM
For the video poker i get the following errors:

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /casino/vidpok_redeal.php on line 151

Warning: Wrong parameter count for max() in /casino/vidpok_redeal.php on line 187

Warning: Wrong parameter count for min() in /casino/vidpok_redeal.php on line 187

Line 151-71 in the casino/vidpok_redeal.php file reads:

while($row=mysql_fetch_array($result)) {
$f[$i] = $row['card'] % 13;
$s[$i] = floor($row['card']/13);
$f2 = $f[$i];
$s2 = $s[$i];
$fcount[$f2]++;
$scount[$s2]++;
if($s2==0)$cardfile = "casino/cards/spades-";
else if($s2==1)$cardfile = "casino/cards/diamonds-";
else if($s2==2)$cardfile = "casino/cards/hearts-";
else if($s2==3)$cardfile = "casino/cards/clubs-";

if($f2+2<11)$cardfile .= ($f2+2) . "-150.png";
else if($f2+2==11)$cardfile .= "j-150.png";
else if($f2+2==12)$cardfile .= "q-150.png";
else if($f2+2==13)$cardfile .= "k-150.png";
else if($f2+2==14)$cardfile .= "a-150.png";

eval('$t_cards .= "' . fetch_template('casino_vidpoker_cards') . '";');
$i++;
}

line 186-8 reads:

{
if ((max($f) - min($f)) == 4) $straight = max($f)+1;
}

cuphongle
10-03-2007, 11:19 PM
sweet, thanks!

Andrew Green
10-04-2007, 02:03 AM
For the video poker i get the following errors:


Line 151-71 in the casino/vidpok_redeal.php file reads:



line 186-8 reads:


There is a little error in there

This:

while($row=mysql_fetch_array($result)) {

should be this:

while($row=$db->fetch_array($result)) {

Which might solve that, otherwise I have to do a little more digging into it.

sandt38
10-04-2007, 11:00 AM
Yeah Andrew, that worked. I also wound up with an unexpected error in line 152 after resolving the error in line 151 which was easily remedied by removing the first "&" in the line (line 152 I mean). But everything looks good right now.

It was:
while($row=$db->fetch_array($result)) {
&nbsp;$f[$i] = $row['card'] % 13;

But the repaired code is:
while($row=$db->fetch_array($result)) {
nbsp;$f[$i] = $row['card'] % 13;

Works great too, in my first hand I got a full house, Jacks over 7s.

sandt38
10-04-2007, 11:06 AM
Also, it would be great if we could add some larger chip denominations. maybe 50s, 100s, 500s, and 1000s. I do have a lot of bettors on my board, and they rake in the cash on my bookie.

They are dying for a multiplayer poker too... in house tourneys would be awesome. I know it is in the works, I just wanted you to know how much I, and my board, are anticipating it.

Andrew Green
10-04-2007, 12:57 PM
Higher chip amounts is on the to do list for this weekend.

Vi3t4Lov3
10-04-2007, 02:54 PM
how can I increase the bet money 1,5,10 too small
can you change to 10,50,100 or 100,500,1000 please thank you

Andrew Green
10-04-2007, 02:55 PM
how can I increase the bet money 1,5,10 too small
can you change to 10,50,100 or 100,500,1000 please thank you

Higher chip amounts is on the to do list for this weekend.


wait for it ;)

dyna88
10-04-2007, 03:33 PM
Blackjack allows you double down after you have already received a card and you can also hit even if you have 21.....

Andrew Green
10-04-2007, 03:43 PM
double down rules vary, I choose to allow it at any time. Any number of cards, any total, and after splits. Splitting can be done more then once as well.

Mark.B
10-04-2007, 03:58 PM
In IE the Javascript that displays your tickets from a previous draw doesn't work...it's got a yellow exclamation mark in the browser and clicking the link on the date of the draw does nothing. Seems to work in FF though.

Andrew Green
10-04-2007, 04:09 PM
breaks in Opera too... added to todo list for the weekend...

Globe
10-04-2007, 04:56 PM
is this compatible with vB credits?

Richard1964
10-04-2007, 05:18 PM
is this compatible with vB credits?

YES, it is.

Mark.B
10-04-2007, 06:43 PM
breaks in Opera too... added to todo list for the weekend...
Thanks.

Please don't think me critical in pointing out the things I have, I like this modification and my aim is only to help you iron out the bugs.

Each time I find something I just throw it into the thread.

Andrew Green
10-04-2007, 06:46 PM
not at all, I can't fix things if I don't know about them :)

Bug reports are always helpful, this is my first attempt at doing anything using the VB product system / api, so I'm still learning as I go :D

sandt38
10-04-2007, 06:52 PM
is this compatible with vB credits?

In the setup change the cash field to credits. Even if you have renamed your cash, just change it to credits. I use both on my board and they work great together.

evesve
10-04-2007, 07:00 PM
This is a great mod!

Some small questions in Black Jack and Video Poker.
Can you make it to show points after each card (BJ)?
Can you make the cards 25% smaller?(BJ and VP, Maybe a option to show diffrent size??)
How can I manually give members "money"?
How can I change from 500 to ??? from start?
I would give members diffrent value depends on the membergroup.
I have it as a test now, how can I reset the points to default?

Andrew Green
10-04-2007, 07:08 PM
This is a great mod!

Some small questions in Black Jack and Video Poker.
Can you make it to show points after each card (BJ)?

Probably, it is calculated, just not displayed. So it shouldn't be hard.


Can you make the cards 25% smaller?(BJ and VP, Maybe a option to show diffrent size??)

Once again, not much of a problem, just involves resizing the image files. Something I plan to seperate in a seperate file with the next update for ease of downloading. No need to redownload all the images every time.


How can I manually give members "money"?

Admincp, user profile. It's at the bottom of the first column.


How can I change from 500 to ??? from start?


A reset everyone to ___ will sneak in there soon, you could manually update it through phpmyadmin or some other mysql interface if you really needed to:

UPDATE ___user SET casino_cash = ____;

just add your table prefix and the amount you want to change it to in there.


I would give members diffrent value depends on the membergroup.


Hadn't really planned that one, I'll definitely consider adding a option to give extra to everyone in a user group. Maybe as a monthly allowance for certain groups? (ex. supporting members)



I have it as a test now, how can I reset the points to default?

SQL query above for now, in admincp in the near future.

Mark.B
10-04-2007, 07:27 PM
A question I'm getting asked quite a lot by members relates to the sports betting feature.

People want to know what the odds are, what they will win, etc etc, and I'm afraid I haven't managed to work that out yet.

Any advice greatly appreciated.

evesve
10-04-2007, 07:39 PM
Probably, it is calculated, just not displayed. So it shouldn't be hard.


Once again, not much of a problem, just involves resizing the image files. Something I plan to seperate in a seperate file with the next update for ease of downloading. No need to redownload all the images every time.


Admincp, user profile. It's at the bottom of the first column.



A reset everyone to ___ will sneak in there soon, you could manually update it through phpmyadmin or some other mysql interface if you really needed to:

UPDATE ___user SET casino_cash = ____;

just add your table prefix and the amount you want to change it to in there.



Hadn't really planned that one, I'll definitely consider adding a option to give extra to everyone in a user group. Maybe as a monthly allowance for certain groups? (ex. supporting members)




SQL query above for now, in admincp in the near future.

...and I love mod with REAL support!
Thanks! :up:

Andrew Green
10-04-2007, 08:06 PM
A question I'm getting asked quite a lot by members relates to the sports betting feature.

People want to know what the odds are, what they will win, etc etc, and I'm afraid I haven't managed to work that out yet.

Any advice greatly appreciated.


I added a more detailed description to the initial post, hopefully that helps. Basically its a pool, everyone puts there money in, and the winners divide the pot based on the portion they put in on the winning outcome. Putting in 15, when 100 had been bet in total on the winner gives you 15% of the total bet on all possible outcomes.

evesve
10-04-2007, 08:30 PM
SQL query:

UPDATE vb3_user SET casino_cash = 1000


UPDATE vb3_user SET casino_cash = 1000 where usergroupid = 6

works fine!!!

Mark.B
10-04-2007, 08:47 PM
I added a more detailed description to the initial post, hopefully that helps. Basically its a pool, everyone puts there money in, and the winners divide the pot based on the portion they put in on the winning outcome. Putting in 15, when 100 had been bet in total on the winner gives you 15% of the total bet on all possible outcomes.
Thanks...I have actually added most of that to the Sports Pool template so people know what's going on...as per screenshot below. Hope that's ok.

Andrew Green
10-04-2007, 09:40 PM
not a problem at all, I might even steal the idea and add a explanation to the template as well ;)

Robp57
10-04-2007, 09:58 PM
Good Job Andy............My staff and members wont leave me alone with questions.......
Looking forward to your updates......
Works fine and they all love it.....
Thanx

Andrew Green
10-05-2007, 02:41 AM
.12 should clean up a few little things and add some of the requested options.

stangger5
10-05-2007, 02:50 AM
The cards reduced.zip still look like there are 150X215...

Andrew Green
10-05-2007, 02:54 AM
and so they do... uploaded the wrong folder :D

Fixed it though ;)

Greek Wizard
10-05-2007, 06:17 AM
This is a great mod, nice to see another Canadian make it too.

thanks.

However one bug report.

in blackjack, when the dealer has two cards in the begining, one is hidden and one is shown, BUT the total is shown for both cards (thus making the hidden card known)

I have attached an image.

Also, it works fine with vbbux (gasp, yes I am still using it), however when it comes up it has 4 decimal points, while the rest of my site only uses two. Alos, I am not sure how it is sorting the top 10, but it's not by value, seems to be user_id.

Would like to see a roulette (maybe from the other less polished casino), and some other games if possible, but IMO you are off to an awesome start.

https://vborg.vbsupport.ru/external/2011/02/1.gif

Globe
10-05-2007, 10:46 AM
YES, it is.

:) ok THX i tested :)

dyna88
10-05-2007, 10:49 AM
double down rules vary, I choose to allow it at any time. Any number of cards, any total, and after splits. Splitting can be done more then once as well.

Could there be options added to not allow this?

Robp57
10-05-2007, 11:57 AM
Hey Dyna.........
It is also a big problem with Blackjack and seeing the card total when the game starts....
You know how much the dealer has, but can only see the one card.....
Can you disable the point count untill you stay?
Love the upgrades too.....
But you should let all know which files need to be uploaded and which ones dont.....just to upgrade.....
I am very pleased with this and will continue to use.......Good Job

Now if we only had multiplayer......lol

Andrew Green
10-05-2007, 12:54 PM
Blackjack showing the dealers hand is fixed, if you've installed between the update and this post replace the existing 'blackjack_deal.php' file with the new one attached to the main post.

Andrew Green
10-05-2007, 12:56 PM
Could there be options added to not allow this?

Certainly possible, does anyone else want this?

I'm thinking 3 switches.
DD after split yes/no
DD with any number of cards yes/no
DD with any value (rather then just 10 & 11) yes/no

Andrew Green
10-05-2007, 01:05 PM
Also, it works fine with vbbux (gasp, yes I am still using it), however when it comes up it has 4 decimal points, while the rest of my site only uses two. Alos, I am not sure how it is sorting the top 10, but it's not by value, seems to be user_id.


It was designed with integers as the cash value in mind, if vbux is the only one that uses a decimal it shouldn't be hard to add a few "round()" functions anywhere things get displayed, however bets will still only work in whole numbers. (ie you can't bet $1.50 in the sportspool)

I'll look into it though.


Would like to see a roulette (maybe from the other less polished casino), and some other games if possible, but IMO you are off to an awesome start.


More games will come ;)

Mark.B
10-05-2007, 06:26 PM
...

Andrew Green
10-05-2007, 06:40 PM
did you make any template changes to the old version before updating? If so revert them, sounds like that is the problem. (casino templates, not any templates in there ;))

Mark.B
10-05-2007, 06:46 PM
Looks like it might be that...I reverted the wrong one.....it's the _intro ones that need reverting. I only did the _main.

Thanks.

Greek76
10-05-2007, 11:05 PM
Will this work with vbplaza?

Andrew Green
10-06-2007, 12:18 AM
Will this work with vbplaza?

Yes, it will work with any cash field that is in the user table. You just have to set it in the admincp.

Jason Black
10-06-2007, 01:16 AM
where does the casino.php file go?

Andrew Green
10-06-2007, 01:25 AM
main forum folder, same place as "index.php"

if it's the site in your sigline: http://www.rapfeinds.com/casino.php

EmpireZ
10-06-2007, 05:00 AM
Great Job Andrew.

One thing is that when members buy a lottery ticket, they don't have a way of getting back to the casino homepage. The navbar breadcrumb is forum and then under is blackjack, while they are in the lottery. Im using version 12.
Thanks !!

Andrew Green
10-06-2007, 05:44 AM
Added to the list of things for the next update, which will be bigger and include a slots game as well as a few other configuration options :)

EmpireZ
10-06-2007, 06:34 AM
Thanks.

I didn't have a navbar link either, maybe that had something to do with it. :p

Cigarcritic
10-06-2007, 06:57 AM
Works great in 3.6.8!

The ticket price in the Lotto does not update. It's hung on $2.

Can we get a setting for the numbers that can be selected? I'd like to see "0"-"9" for a Pick Three, and the same for the number of balls. In Texas we have Pick Three, Just pick three numbers from "0" to "9". Better odds for a small group.

And a setting for how many ticket a User can buy per lottery. At $2 to $10 dollars, a user could buy an unlimited number of tickets.

For Video Poker and BlackJack, some custom button images would be nice.

A reset chips option for the users.

Thanks for this excellent hack and I'm looking forward to future updates. PM me your Paypal so I can send you a Donation.

AuroraStorm
10-06-2007, 12:26 PM
This looks very interesting and promising. I'll upload when you finish beta testing. Multiplayer games is something my board eagerly awaits...

Question: is it possible to add a spades game or better yet, something like an Uno game? My members would never log off if we had those two games...

Andrew Green
10-06-2007, 02:53 PM
Works great in 3.6.8!

The ticket price in the Lotto does not update. It's hung on $2.


It will when the current draw ends, changing the settings effects the next draw, but the one that is already running finishes before anything changes.


Can we get a setting for the numbers that can be selected? I'd like to see "0"-"9" for a Pick Three, and the same for the number of balls. In Texas we have Pick Three, Just pick three numbers from "0" to "9". Better odds for a small group.


20 and 3 is as low as it goes right now, but allowing lower numbers shouldn't be a problem. 10 seems to mess up the payouts though, it ends up paying 135% or so over time, 15 is still good though :)


And a setting for how many ticket a User can buy per lottery. At $2 to $10 dollars, a user could buy an unlimited number of tickets.


So you want a cap? Like no more then X tickets? ( I don't really see a reason to limit tickets to be honest, I can go to the corner store and buy as many as I like)


For Video Poker and BlackJack, some custom button images would be nice.


Yes, but it was make everything work first, then make it pretty :D


A reset chips option for the users.


I don't know, I just see users dropping the highest value they can into a high payout option and resetting until they win...


Thanks for this excellent hack and I'm looking forward to future updates. PM me your Paypal so I can send you a Donation.

paypal@innovativema.ca (There is a link at the top in the first post), thanks :D

Andrew Green
10-06-2007, 02:55 PM
This looks very interesting and promising. I'll upload when you finish beta testing. Multiplayer games is something my board eagerly awaits...

Question: is it possible to add a spades game or better yet, something like an Uno game? My members would never log off if we had those two games...

I'd have to do some research, No idea what spades is and has been a long time since I played Uno...

But Poker will come first regardless as I figure there is more interest for that and I've already written a few of the pieces for it :)

aztecboi2003
10-06-2007, 03:00 PM
Any idea when this next version will come out? This weekend perhaps? Will it be out of beta? I really want to install this, just waiting patiently. looks good what you have done with it so far.

Andrew Green
10-06-2007, 03:23 PM
I expect the next update by Monday.

It will include a slots game (preview attached. AJAX powered and yes, wheels do spin ;)) as well as all of the fixes for bugs I know about, which are pretty minor at this point (navbar breadcrumbs and things like that)

Should also give more options in the setup, like turning on/off each chip value per game, controlling double down options in BJ and some more player / game stats.

It should be pretty much stable, not really "finished" in the sense that I will still have a couple games to add and need to phrase everything.

1.0 will have a minimum of a well tested multiplayer Texas Hold 'em table, and probably a couple other games as well, so it's a ways off. But along the way each individual game should be pretty stable. I also have some cleaning up on some of the visuals that I want to do, some things where just put in to be functional.

Cigarcritic
10-06-2007, 04:09 PM
So you want a cap? Like no more then X tickets? ( I don't really see a reason to limit tickets to be honest, I can go to the corner store and buy as many as I like)

I run a cigar forum and we can pool for cigars. Having a limit on tickets makes the odds fair.

I don't know, I just see users dropping the highest value they can into a high payout option and resetting until they win...

But it's just a game...not real money. :D
Even with Pluginpoker.com the members can reset their chips.

paypal@innovativema.ca (There is a link at the top in the first post), thanks :D

Sending after this message.

Poker does not pay out on A, 2, 3, 4 ,5 straight.

How about an option for the members to place their own Betting Pools? It's too time consuming to post all the games that members want listed.

Cigarcritic
10-06-2007, 04:15 PM
It will include a slots game (preview attached. AJAX powered and yes, wheels do spin ;))


Looks good!

Andrew Green
10-06-2007, 04:25 PM
I run a cigar forum and we can pool for cigars. Having a limit on tickets makes the odds fair.


Gotcha, but I might have something better.

Also looking at a raffle addition, This would allow a fixed ticket price, limit on tickets and options to have the winner get a fixed cahs prize, total entered or some other prize (which could be a real world item)



But it's just a game...not real money. :D
Even with Pluginpoker.com the members can reset their chips.


True enough, I've just been thinking along the lines of "If you want more, earn them by posting and coming on daily and referrals" :) Added as a possible addition in the future.


Sending after this message.


Thanks much :)


Poker does not pay out on A, 2, 3, 4 ,5 straight.


Nope, nor a straight flush, thanks, will fix for next update


How about an option for the members to place their own Betting Pools? It's too time consuming to post all the games that members want listed.

Will come, based on usergroup. My reason for doing it this way was I found looking up odds to time consuming, so I am all for less work :D

aztecboi2003
10-06-2007, 04:30 PM
Slots looks great. As far as the ufc photo, I could have nfl teams there right? It's totally configurable to whatever betting event I want.

Andrew Green
10-06-2007, 04:40 PM
Slots looks great. As far as the ufc photo, I could have nfl teams there right? It's totally configurable to whatever betting event I want.


Yes, I have a martial arts site so MMA events get listed :)

You set up your groups as you need them, (NFL, NBA, NHL, etc)

kylek
10-06-2007, 09:50 PM
This is getting better by the day!! If you like it dont forget to click "MOTM"

For now we would like to remove the Top Players section, where or what needs to be removed so it will not show? Did a quick look in the templates but nothing jumped out right away.

Thanks!!

Ski-Whiz
10-06-2007, 10:17 PM
Few questions........

Have you looked into providing directions on using other point systems??

Also, when the bets are being made in the pool, can anyone see who bet????

I'd like to keep the bets private, meaning no one can see who bet what.. Even after the results..

Ski-Whiz
10-06-2007, 10:33 PM
Also, what are the possibilities of adding more games? Is there a bunch you could add? or just a few more??

Just asking so I know what to expect..

ChU v2
10-06-2007, 11:15 PM
Looking better, I'm still waiting on the hold em integration to fully install. BTW, your I tried your demo and the usergroup doesn't have perms to access to the casino.

EmpireZ
10-06-2007, 11:31 PM
Looking better, I'm still waiting on the hold em integration to fully install. BTW, your I tried your demo and the usergroup doesn't have perms to access to the casino.

This was mentioned in the release. :p

If you want to see a demo, it's live at http://innovativema.ca, it does require registration though as it needs a userid to attach your money too

Ski-Whiz
10-06-2007, 11:41 PM
Not sure if anyone else had this issue, but my font is white.

The body can't be seen, as it matches the background..

Not sure what is different on my site than everyone else's, but by default it's white (text).

EDIT: Nevermind, my Body text color was white.. Not sure what this affects on my site, as my body text is all black...

Ski-Whiz
10-06-2007, 11:42 PM
Also, something I think that would help this out immensely, the ability for a certain usergroup to place a Sporting event from the bet page.

Basically so they don't have to enter the admincp or modcp everytime they want to add an event.

Also the ability to settle the bet on the page....

ChU v2
10-06-2007, 11:54 PM
This was mentioned in the release. :p

I read that. I registered, still having the perms issue.

edit: nevermind had to verify the account :p

Ski-Whiz
10-07-2007, 03:51 AM
Also, just a suggestion, put an option where members can buy tickets in bulk..

Since tickets are max 10 points, some members might want to drop some major money..

I'm not saying grab a blank amount, but maybe a drop down where they can by them in packs of 5-20???

Andrew Green
10-07-2007, 05:49 AM
This is getting better by the day!! If you like it dont forget to click "MOTM"

For now we would like to remove the Top Players section, where or what needs to be removed so it will not show? Did a quick look in the templates but nothing jumped out right away.

Thanks!!

Glad you like it :)

It's in the casino_index_main template, near the bottom. Pulling this section out should do it:

<table class='tborder' align='center' border='0' cellpadding='6' cellspacing='1' width='250px;'>
<thead>
<tr align='center'>
<td class='tcat' colspan='2'>Top Players</td>
</tr>
</thead>
<tbody>

$t_players

</tbody>
</table>

However remember to revert templates on updates if you make changes as it may effect other things. This section will likely end up changing, I plan to have a few other top 10 lists that rotate through and a link to a main stats page in there ;)

Few questions........

Have you looked into providing directions on using other point systems??


I will, but I have to go through them and figure out what fields they use.


Also, when the bets are being made in the pool, can anyone see who bet????

I'd like to keep the bets private, meaning no one can see who bet what.. Even after the results..

Yes, bets are private.

Also, something I think that would help this out immensely, the ability for a certain usergroup to place a Sporting event from the bet page.

Basically so they don't have to enter the admincp or modcp everytime they want to add an event.


Also the ability to settle the bet on the page....

On the to do list already, next little while that will get done.

Also, just a suggestion, put an option where members can buy tickets in bulk..

Since tickets are max 10 points, some members might want to drop some major money..

I'm not saying grab a blank amount, but maybe a drop down where they can by them in packs of 5-20???

Not thought of that, but certainly a option.



Also, what are the possibilities of adding more games? Is there a bunch you could add? or just a few more??

Just asking so I know what to expect..

Well, I write them all myself, so more are coming, they just take time. Slots should be added in the next couple days, and others will follow over time :)

Anyways, here's some of the things that are coming:

Already Done for next release:
- New game: Slots machine
- Sportspool now allows closing / cancelling events that haven't occurred yet.
- Can turn different chip denominations on/off on a per game basis
- Fixed Aces as low in a straight on poker
- Breadcrumbs are all set up properly
- Stats page is partially done. It tracks how much each person has put into and got out of each game, so there are a lot of stats that can be displayed.

Will likely be done for this next one:
- Some house rules settings for blackjack. When you can double down, whether you can split multiple times.


Other things on which I am looking at:
- Roulette, not sure on this one, but might write it eventually. Not a terribly hard module to build.
- A raffle system. Buy tickets, one person wins. Prize can be a fixed amount, winner takes all, or something outside of that (supporting membership, physical prize, whatever you like)
- Multiplayer Poker, some of the functions are written, I've figured out most of the tricky pieces (simple chat, picking the best possible hand, finding the winner) just a matter of putting them together and turning it into a game. Still, this is a bigger piece and will take longer. Will start with Texas Hold em, however other rules might follow later on.
- Sportspool needs some polishing, initially I wrote a lot of this just for my site and it shows on that one especially. The setup interface needs work and to become something non-admins can do.
- Better graphics. The chips are ugly and where thrown together quickly, the buttons are about as plain as they could be.

Ski-Whiz
10-07-2007, 05:55 AM
Awesome!!!

I can say one thing, if you get a multi player game (live) going, this will be a HUGE mod!!

I didn't want to swamp you with a wish list, just providing some feedback. :D

Thanks for getting back to me.. Also, once this comes out of beta, I'd as for a major addition mod forum on here. :D

My staff is testing the casino out now.. So far so good.

Andrew Green
10-07-2007, 06:03 AM
Wish lists are good, I might not do everything everyone asks for, but I'll definitely use the better ideas :)

Multiplayer is obviously the biggest piece, which is why I'm leaving it until I got a fairly good handle on the vB api, first product for me so it's a learning experience.

Robbed
10-07-2007, 06:46 AM
If we set the daily bonus, it seems like it awards every hour when the scheduled task runs.

evesve
10-07-2007, 10:15 AM
Its getting better and better!!! :D
Perfect card size!
Mass Cash Adjustments works fine!
(Can you edit singel user there too?)

Now I wait for multiplayer Texas Holdem! :up: ;)

Cornie
10-07-2007, 12:38 PM
This add-on is hard-encoded. Can you make this with phrases. Is better to translat in other language.

sandt38
10-07-2007, 01:05 PM
Now I wait for multiplayer Texas Holdem! :up: ;)

My staff and members are clamoring for the same.


Thanks.

Andrew Green
10-07-2007, 02:08 PM
If we set the daily bonus, it seems like it awards every hour when the scheduled task runs.

I fixed that on my live site, but guess I forgot on my development one, will be fixed next update, and can be manually fixed until them if you want.

This add-on is hard-encoded. Can you make this with phrases. Is better to translat in other language.

Yes, but that will likely be one of the last things I do.

Cigarcritic
10-07-2007, 07:29 PM
DB Error when I settled a bet.

Invalid SQL:

UPDATE casino_bet_stats
SET won = won + 210
WHERE userid = 9
AND gameid =;

MySQL Error : 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 '' at line 4
Error Number : 1064

Andrew Green
10-07-2007, 07:45 PM
DB Error when I settled a bet.

Invalid SQL:

UPDATE casino_bet_stats
SET won = won + 210
WHERE userid = 9
AND gameid =;

MySQL Error : 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 '' at line 4
Error Number : 1064

Fixed in next update, temporary measure:

line 21 of admincp/casino_sb_settle.php

AND cs1.switch2='sportspool.php'


too

AND cs1.switch2='sportspool'

Andrew Green
10-07-2007, 08:19 PM
.20 is up, with a new game :)

duckdodger
10-07-2007, 08:37 PM
Thanks, this is a really cool mod. I haven't even told anyone about it or put links to the page yet and my members have still found it :D

Ski-Whiz
10-07-2007, 08:40 PM
Nice... Installed .20 and works flawlessly!!

SBlueman
10-07-2007, 09:02 PM
Very cool. The staff is loving it so far.

Someone did ask....is it possible to add sound?

sandt38
10-07-2007, 09:26 PM
I have also installed .20 and I am quite impressed. I really love this hack. I have even made my own markers to jazz up the casino a bit. I love how you made it so easy to add your own markers, too.

Is there any way to disable the lottery and sports betting pool options on the stats page? I have disabled the use of them (I use vBookie and vBCredits, thereby making the need for these non-existant) but they still show up on the stat sheets.

sinisterpain
10-07-2007, 09:26 PM
The template for slots "casino_slots_play" is uncached also getting the problem hit three cherrys gives payout undefined" and the obvious fruit outside the boxes(see attached). Using IE7

Andrew Green
10-07-2007, 09:26 PM
Very cool. The staff is loving it so far.

Someone did ask....is it possible to add sound?


Javascript and sound don't really get along very well. I know IE can do it, but I've not seen a method of doing it in other browsers.

Andrew Green
10-07-2007, 09:27 PM
The template for slots "casino_slots_play" is uncached also getting the problem (see attached)

Internet explorer? I can't test in that at home, and it has a tendency to screw with CSS...

Andrew Green
10-07-2007, 09:29 PM
I have also installed .20 and I am quite impressed. I really love this hack. I have even made my own markers to jazz up the casino a bit. I love how you made it so easy to add your own markers, too.

Is there any way to disable the lottery and sports betting pool options on the stats page? I have disabled the use of them (I use vBookie and vBCredits, thereby making the need for these non-existant) but they still show up on the stat sheets.

I'll fix that for the next update, only have games that are turned on in there.

sinisterpain
10-07-2007, 09:34 PM
Internet explorer? I can't test in that at home, and it has a tendency to screw with CSS...
see updated post above

sandt38
10-07-2007, 09:46 PM
Shoot, the issue with the dealers total is showing up in blackjack again in the .2 DL.

Andrew Green
10-07-2007, 09:55 PM
Fixed file is in main post, archive is corrected. That's what I get for fixing a problem on a different computer...

sandt38
10-07-2007, 09:57 PM
I just replaced the blackjack_deal.php with the .php from .12. I assume this was the correct fix (rather then having to re-dl and load the whole thing again), or was there more added to the .php for this update?

TTG
10-07-2007, 10:00 PM
Installed and working perfectly using the latest version 2 vbbux / vbplaza points system.

Great addition .. thanks Andrew

Andrew Green
10-07-2007, 10:06 PM
I just replaced the blackjack_deal.php with the .php from .12. I assume this was the correct fix (rather then having to re-dl and load the whole thing again), or was there more added to the .php for this update?


Added a new one to the first post, should replace it with that one.

sandt38
10-07-2007, 10:20 PM
Added a new one to the first post, should replace it with that one.

You can now split 2 different face cards. I just split a J and a K.

SBlueman
10-07-2007, 10:42 PM
Slot won't work, got 3 rows fruits from the top to the bottom of my screen. got 3 cherries in a row, but it says payout undefinded.

rwilkins108
10-07-2007, 10:56 PM
edit... never mind, everything works great :D

can't get slots to work in firefox, if I click Slots, it just updates the casino page....

Tulsa
10-07-2007, 10:58 PM
Slots are working fine with firefox for me.

rwilkins108
10-07-2007, 11:04 PM
can't get slots to work in firefox, if I click Slots, it just updates the casino page....

sorry, my mistake, updated all files but casino.php... working great now!

Thanks!

Andrew Green
10-07-2007, 11:23 PM
You can now split 2 different face cards. I just split a J and a K.


Always could, I've never played where you couldn't?

Andrew Green
10-07-2007, 11:25 PM
Slot won't work, got 3 rows fruits from the top to the bottom of my screen. got 3 cherries in a row, but it says payout undefinded.

Internet explorer thing, Will hopefully have a fix tomorrow. Half the problem I know how to work around, but busy for tonight, so I'll try and get this tomorrow afternoon. For now it's Firefox / Opera / etc only, no IE ;)

SBlueman
10-07-2007, 11:32 PM
Internet explorer thing, Will hopefully have a fix tomorrow. Half the problem I know how to work around, but busy for tonight, so I'll try and get this tomorrow afternoon. For now it's Firefox / Opera / etc only, no IE ;)

I keep trying to educate members on my site....STOP USING IE! When will they learn???

Robbed
10-08-2007, 12:54 AM
I fixed that on my live site, but guess I forgot on my development one, will be fixed next update, and can be manually fixed until them if you want.



Yes, but that will likely be one of the last things I do.

Was this fixed in the new version? it;s still doing it for me.

Also on the stats page if you can have per game stats like top a blackjack etc

Cigarcritic
10-08-2007, 02:06 AM
The template for slots "casino_slots_play" is uncached also getting the problem hit three cherrys gives payout undefined" and the obvious fruit outside the boxes(see attached). Using IE7

Same problem here with IE.

Andrew Green
10-08-2007, 04:32 AM
Was this fixed in the new version? it;s still doing it for me.


Yes, but I'm new to the product system, so it might just not be updating the times. In scheduled tasks go to "Update Casino cash" and change hour from a * to whatever time you want it to run, Middle of the night is best.


Also on the stats page if you can have per game stats like top a blackjack etc

Yes, I'll probably expand on the stats page at some point.

rwilkins108
10-08-2007, 02:17 PM
Still lovin' this casino!

In the card games, is there anyway to not refresh the screen each time you perform an action?

Also, can the user's total always be displayed instead of when just betting.

1 more, how about :
You Win or Dealer Wins in Blackjack
Instead of Pair +25, something like Pair, you win 25 for Poker

Keep up the great work!
:D

Andrew Green
10-08-2007, 02:35 PM
Still lovin' this casino!

In the card games, is there anyway to not refresh the screen each time you perform an action?


The screen doesn't refresh, just the play area, card games and slot machine use AJAX and do the minimal refreshing they can get away with. So when you perform a action it clears the area and sends the request to the server for an update on what cards and buttons to display, but everything outside of that is not refreshed.


Also, can the user's total always be displayed instead of when just betting.

1 more, how about :
You Win or Dealer Wins in Blackjack
Instead of Pair +25, something like Pair, you win 25 for Poker

Keep up the great work!
:D

When I get to phrasing I'll be looking at all my wordings and things :)

Andrew Green
10-08-2007, 06:47 PM
v .21
Slots should work in Internet Explorer now
Template should cache properly
Inactive games aren't included in stats

evesve
10-08-2007, 08:01 PM
Better and better!

- Added stats page, main casino page stats rotate through the 5 on this page now.
Can You make a choise in CP for the rotate?
I prefer to have "Richest Players" there always...

Andrew Green
10-08-2007, 08:05 PM
I can, but for now change this:

if($ismainpage)
$page = (rand() % 5) + 1;


too this:

if($ismainpage)
$page =5;


in the stats.php file on line 10 & 11.

And it will only show the richest players box.

Jason Black
10-08-2007, 08:40 PM
so the casino files is on it's own in the main forum root directory? or they go in a seperate floder?

Uhmmm the casino.php, goes in the admin cp right?

Andrew Green
10-08-2007, 08:42 PM
casino.php goes in your main forum directory. On your site that would be here:

http://www.rapfeinds.com/casino.php

everything else goes in the folders the archive has them in

Jason Black
10-08-2007, 08:53 PM
Ohhhhhhhhhh i see
Thanks Andrew....you are the greatest

kylek
10-08-2007, 08:55 PM
I can, but for now change this:

if($ismainpage)
$page = (rand() % 5) + 1;
too this:

if($ismainpage)
$page =5;
in the stats.php file on line 10 & 11.

And it will only show the richest players box.

What would be needed to just display Most Won always instead of richest players?
Thanks!!

Andrew Green
10-08-2007, 09:01 PM
What would be needed to just display Most Won always instead of richest players?
Thanks!!

Just a matter of changing the "5" to the one you want:

1 - Individuals stats
2 - Total stats
3 - Most Won
4 - Luckiest
5 - Richest

sandt38
10-08-2007, 09:58 PM
Now slots doesn't display any images at all

I believe it is something in the products_casino.xml Because reloading the slots .phps did nothing, but reloading the product file brought back the images.

Andrew Green
10-08-2007, 10:03 PM
did you upload the image? it changed, now it's one image rather then a seperate one for each fruit. If not upload the slotwheel.png file to the casino/cards folder

kylek
10-08-2007, 11:28 PM
Andrew,

Got a weird problem on one site, went from .20 to .21 and now the pay window where it says what you won in slots is not showing, any suggestion where to look or what might have not uploaded right, or is it the style we are using?

70802

Andrew Green
10-08-2007, 11:47 PM
Did you modify any templates by hand? If so they need to be reverted.

Is it there but in a black font?

kylek
10-08-2007, 11:50 PM
Oops sorry, just saw that the text is black and hidden in this style, looking at the casino_slots_main to see where I can change it now.

Andrew Green
10-09-2007, 12:00 AM
Change this:

<td style='vertical-align:top;width:150px;text-align:center;' 'class='thead'><p style='font-size:18pt;'>Payout<br/><span style='font-size:36pt;font-weight:bold;' id='outcome'></span></p></td>


To this:

<td style='vertical-align:top;width:150px;text-align:center;' 'class='thead'><span style='font-size:18pt;'>Payout</span><br/><span style='font-size:36pt;font-weight:bold;' id='outcome'></span></td>

That should fix it and will go into the next update.

gwerzal
10-09-2007, 12:57 AM
Hi

I have just installed the newest version of the casino (0-21) and there isn'e a link showing in my admincp.

Any ideas why it wouldn;t be there.

I installed it on a test forum with the version 0-20 and it worked fine.

Any help is much appreciated.
Ben Jones

gwerzal
10-09-2007, 01:01 AM
Is there any way of adding more set outcomes to the sports betting pool?

Andrew Green
10-09-2007, 01:11 AM
Hi

I have just installed the newest version of the casino (0-21) and there isn'e a link showing in my admincp.

Any ideas why it wouldn;t be there.

I installed it on a test forum with the version 0-20 and it worked fine.

Any help is much appreciated.
Ben Jones


Did you upload all of the admincp files, including the includes/xml folder?

Andrew Green
10-09-2007, 01:11 AM
Is there any way of adding more set outcomes to the sports betting pool?


Not sure what you mean?

Jason Black
10-09-2007, 01:15 AM
can you intergrate this into VB plaza?

Ski-Whiz
10-09-2007, 01:19 AM
can you intergrate this into VB plaza?

Yes... In the point system field, use "vbbux" (assuming you haven't renamed your point system default in vbplaza)

stangger5
10-09-2007, 02:21 AM
In the slots,,if you bet 10 and you get:
one cherry ,,you get 10 points,,
two cherries ,, you get 30 points,,
Three cherries ,, you get 10 points...

Shouldnt it pay out 100 points for three cherries ??

Andrew Green
10-09-2007, 02:32 AM
In the slots,,if you bet 10 and you get:
one cherry ,,you get 10 points,,
two cherries ,, you get 30 points,,
Three cherries ,, you get 10 points...

Shouldnt it pay out 100 points for three cherries ??


It should, and it does for me...?

Can you can force a 3 cherry result and confirm this?

Below (line 142):
$a = (rand() % 64);
$a = $wheel1[$a];
$b = (rand() % 64);
$b = $wheel2[$b];
$c = (rand() % 64);
$c = $wheel3[$c];

add

$a = $b = $c = 1;

in slots_ajax.php

(Make sure the latest versions of all the files are up first too)

stangger5
10-09-2007, 03:05 AM
Below line 142 ??

So it will look like this ??

$a = (rand() % 64);
$a = $b = $c = 1;


I added it there and played some more..
I hit three cherries again and got 100 this time...

Andrew Green
10-09-2007, 03:08 AM
well no, bellow the whole block. but if you hit it twice something is definitely wrong, do other 3 of a kinds pay out properly? (can force them the same way)

stangger5
10-09-2007, 03:09 AM
Its scoring right now....Must have been a one time thing....

Thanks !!

Robbed
10-09-2007, 04:23 AM
Thanks, looks good.

I'm getting Uncached templates: casino_slots_slotimage (21)

SBlueman
10-09-2007, 05:14 AM
I just noticed there are no breadcrumbs setup in the Sports Pool Page (see attached)

Andrew Green
10-09-2007, 11:52 AM
Its scoring right now....Must have been a one time thing....

Thanks !!

I think I know what might have done it, display error rather then a scoring error that could have occured if the server was experiencing heavy lag. Will take care of this, the casino_slots_image template (which isn't even needed anymore) and the sportspool breadcrumbs bugs with the next update.

xxxsaint
10-09-2007, 02:27 PM
the Lottery doesn't seem to be working correctly, I've disabled it on every day , and then enabled it on every day to see if it would " reset " and it still says No Draw Active at this time, please check back later

Andrew Green
10-09-2007, 02:33 PM
I'll look into that, some of the admincp stuff is really not doing a lot of error checking, so doing something it doesn't expect could get funny results.

My guess is that it will start up again, after the next draw time. I believe going to the scheduled task and hitting "Run now" should start a draw up for you though.

Tulsa
10-09-2007, 05:01 PM
On a blackjack it seems to be paying 1:1 instead of 1.5:1, is this intentional?

On the ajax refresh of the card screen, can any adjustments be made to this, like just refreshing the cards themselves and not the title bars above them?

My members are really enjoying this addition, thanks! :)

Andrew Green
10-09-2007, 05:10 PM
No, it should be returning 3:2, I'll look into that.

edit: Found the problem, missing a "else", will be fixed with next update.

kpa4941
10-09-2007, 09:41 PM
Can I integrate this hack with vbcredits. I want my members to use Credits instead of Casino money.

sinisterpain
10-09-2007, 09:46 PM
The Lotto main template wraps to right side.
Looking at the template you have
<html>

need to change to
$stylevar[htmldoctype]
<html xmlns="http://www.w3.org/1999/xhtml" dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">

Fixes the problem

Mark.B
10-09-2007, 09:59 PM
Can I integrate this hack with vbcredits. I want my members to use Credits instead of Casino money.
Yes, you just specify "credits" as the cash to use in the casino options.

kylek
10-09-2007, 10:08 PM
Works great with vbcredits, just set the points awards to 0 for vbcasino also. Only drawback is the many extra decimal points.

Andrew Green
10-09-2007, 10:29 PM
Works great with vbcredits, just set the points awards to 0 for vbcasino also. Only drawback is the many extra decimal points.

I'll cut the decimals off for those using other systems in the next update...

Andrew Green
10-09-2007, 10:57 PM
Works great with vbcredits, just set the points awards to 0 for vbcasino also. Only drawback is the many extra decimal points.

Or disable the plugins that award cash on those actions.

kylek
10-10-2007, 01:16 AM
Hello Andrew - questions about the lottery.

We have two sites set for pick 3 out of 20 numbers.

How is the payout set for these. On both sites with a draw that just happened the number was drawn but shows no winners. Do you have to have all three numbers correct, or does it pay for one number correct, or two, etc.

Here is some tickets recorded on one site for todays draw:

2 10 17
9 10 17
1 2 8
1 2 15
3 6 10
2 8 12
9 10 17

Numbers drawn 6, 16, 19,

Another sites numbers for todays draw:

1 7 9
5 10 16
7 15 17
15 17 19
9 10 16
3 12 18
7 12 18
8 16 18

The numbers drawn were 1, 10, 19.

If you get something for pick 1 right then in the above tickets I should have been a winner 4 times. Yet next to the drawn number it says no winners in the box.

Also how does one know if they win anything in the lottery, is it announced anywhere?

Sorry for the questions, just trying to get it straight as i know members are going to ask the same questions.

Andrew Green
10-10-2007, 01:58 AM
Not announced anywhere, unless it is a full match.

With those 3 x 20 you would need 2 of 3 to win anything.

At the bottom of the casino setup screen it shows the minimum payouts for each number of hits. This is what you would get if you won and no tickets had been bought, however the jackpot goes up. In reality actual payouts will average about double that. Some smaller, some bigger.

On average you would be looking at a JP of 580 and a 2 of 3 win of 11.

Odds of a JP are 1 in 1140
2 of 3 1 in 22

The math behind it should provides a payout over time of about 100% no matter what values you choose. (I ran simulations of millions of draws across the whole range)

kylek
10-10-2007, 04:16 AM
Thank you very much, that helps me and my members a lot!!

wilburshere
10-10-2007, 08:12 AM
loving this mod thank you the slot machine awesome

eurofunny
10-10-2007, 06:14 PM
Yes very nice mod thx. For the Future Version here are my wish:

Multiplayer Onlinescrabble like this one http://ryan.buterbaugh.org/wabble/ :)

hoopsta
10-10-2007, 07:40 PM
where can I change Top 10 money winners to Top 25?

Mark.B
10-10-2007, 07:48 PM
Looking good!

The slots game and the stats page are not covered in the who's online display plugin.

hoopsta
10-10-2007, 07:55 PM
BTW - I can't even see the Top 10 stats

Andrew Green
10-10-2007, 07:58 PM
BTW - I can't even see the Top 10 stats

Meaning you see less then 10? If that is the case then you probably just haven't had 10 people go into the casino yet ;)

If not what is your site's URL? ( the link in your profile is broken.)

hoopsta
10-10-2007, 08:10 PM
sometimes the stats show, sometimes they don't. http://www.pointguardu.com/cats/casino.php

It looks like there is a new stats package but if so it doesn't show up. try refreshing the screen. it disappears.

Andrew Green
10-10-2007, 08:16 PM
sometimes the stats show, sometimes they don't. http://www.pointguardu.com/cats/casino.php

It looks like there is a new stats package but if so it doesn't show up. try refreshing the screen. it disappears.

Try reverting any edited templates, looks like you are using a modified v .1 template on the main screen, that template changed with .2

hoopsta
10-10-2007, 08:18 PM
nice looks awesome. that did it!

Andrew Green
10-10-2007, 08:22 PM
where can I change Top 10 money winners to Top 25?


I think what I am going to do is add some options in the admincp to set a fixed stats type or rotate, as well as how many names to show.

Looking good!

The slots game and the stats page are not covered in the who's online display plugin.

Thanks, will fix with next update.

hoopsta
10-10-2007, 08:39 PM
great idea andrew.... maybe you can add "unluckiest" and funny stuff like that. Is there a way you can add an option where people can choose to cheat? and have like a 2% chance to be successful, but if they get caught they lose x5 the bet or something?

sinisterpain
10-10-2007, 08:41 PM
Secondary usergroups do not work. Members get permisions denied.

Andrew Green
10-10-2007, 09:22 PM
great idea andrew.... maybe you can add "unluckiest" and funny stuff like that. Is there a way you can add an option where people can choose to cheat? and have like a 2% chance to be successful, but if they get caught they lose x5 the bet or something?

More stats is definately doable. Not so sure about the cheating thing though.

Secondary usergroups do not work. Members get permisions denied.


Nope, primary only right now. It's easy enough to switch though, so I can do that with the next update.

Hornstar
10-11-2007, 12:38 AM
would be cool if you could change this: Casino Cash: 250
to Casino Cash (http://www.linkedtocasion.com): $250 in the next update as well

So far I have given it a good testing, and it looks amazing :)

Andrew Green
10-11-2007, 02:53 AM
$ signs can definitely be added.

I'm going to put up a minor update tomorrow to fix all the little things that have come up, and make a few minor cosmetic adjustments. So if anyone else has noticed anything odd please let me know. Next "big" update possibly this weekend, maybe the next will include a new game :)

And the one that seems to be on the top of the wish lists, multiplayer Texas Hold'em is coming along nicely. Screen gets drawn, 10 seats are there, 10 people can join, chat room works, game starts and deals two cards each, then times out and dumps the hand because it doesn't know what else to do yet :D But most of the "hard" stuff is done, just needs a little more time, but it is definitely coming soon.

So there is a little update on where things sit.

ArchangelX
10-11-2007, 02:59 AM
Holy shiat, that would be awesome! If you need ANY help with graphics, just let me know!