Thread: Add-On Releases - MMLotto System
View Single Post
  #4  
Old 08-25-2006, 06:41 PM
micheal332001 micheal332001 is offline
 
Join Date: Apr 2004
Posts: 1,112
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Gizmo5h1t3
ok...installed, and it works fine...AT LAST YEY!!!..lmaO

BUT...theres one prob ive found...

i set it to buy 2 tickets, at 50 points each..(using vbbux)...

i bough a ticket, all is working.....with correct calculation of points deducted as it should....nice....

HOWEVER..

if you refresh the page after you buy the first ticket, it buys a SECOND ticket with the same numbers.....
i did this to see if the jackpot amount was working as it should..ie..increasing with the bought ticket...(as when u buy the first ticket, and it says the ticket is purchased, the "tickets sold" shows zero)......and i found this error...

prolly a simple edit or fix i know, but i just thought id give u a heads up.

also, it hasnt added the cron job....



nope, nothing there mate..................


and one more thing, can u guide me to where i can change the number of points initially for the 3 numbers, 4 numbers and the jackpot??

presently, 3 numbers pays out 10 points, which is pretty useless, as its costing em 50 to buy a ticket??

so how could i set the start off prizes for the lotto to have say......

3 numbers = 1000 points

4 numbers = 4500 points

Jackpot = 25000 points


apart from these teething probs, a cracking hack, seriously....nice work!!
Yes if you refresh the page it will do it again but i will be changing this so it dose not happen.

In 3.5.x you would have to add the cron job yourself something like this.

Name mmlotto system results
file .includes/cron/mmlotto.php

Set the time as you want.

To set the points when the cron job runs edit the includes/cron/mmlotto.php file
and look for this line of code
PHP Code:
$vbulletin->db->query("UPDATE " TABLE_PREFIX "mmlotto_payouts SET fournums = 250"); 
change the 250 to what you want.

for the jackpot look for this line of code
PHP Code:
$vbulletin->db->query("UPDATE " TABLE_PREFIX "mmlotto_payouts SET fivenums = 2500"); 
and change the 2500 to what you want.

If you want to to have the match 3 changed find this.
PHP Code:
$vbulletin->db->query("UPDATE " TABLE_PREFIX "user SET $userscashtable = $userscashtable+$matchthreepayouts WHERE userid= '$match3[userid]' "); 
and after add this line of code
PHP Code:
$vbulletin->db->query("UPDATE " TABLE_PREFIX "mmlotto_payouts SET threenums = 250"); 
and change the 250 to what you want it to be.
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01296 seconds
  • Memory Usage 1,779KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete