Jump to content

Lukeidiot

Members
  • Content Count

    187
  • Joined

  • Last visited

Community Reputation

8 Neutral

About Lukeidiot

  • Rank
    Advanced Member
  • Birthday 01/01/1989

Contact Methods

  • Website URL
    http://SnapChatWeb.com

Profile Information

  • Gender
    Male
  • Location
    New York
  1. Here is what I managed to come up with: function calculateRollLowProfit(game_int, bet, house_edge){ var roll = game_int - 1; var game_int = 100 - game_int; var chance = (100 - game_int); var multiplier = (house_edge / chance); payout = bet * multiplier - bet; payout = toFixed(payout, 5); payout = parseFloat(payout); $('.low .profit2').text(payout); } function calculateRollHighProfit(game_int, bet, house_edge){ var roll = game_int - 1; var chance = (99 - game_int); var multiplier
  2. I am trying to make this complicated JavaScript into a more simple, workable approach. Here is a link to the full source code: http://paste.ubuntu.com/16651803/ I am trying to accomplish the following stats: End Goal: Calculate Profit for Roll High and Roll Low Here is the function I believe is responsible for calculating: namespace("Rollin.Casino.Dice.Stats", function() { var t, e; return t = namespace.use("Rollin.Casino.Dice.Dice"), e = function() { function e(t, e) { this.number = t, this.dice = e }
  3. I think our numbers are different because there are "levels" based on how much you have wagered. For instance I am level 3, and my house edge is only 0.96%. I believe level 1 (your level) house edge is 0.99%.
  4. Yes, my head hurts after using lots of math, but here lies to key: namespace("Rollin.Casino.Dice.Stats", function() { var t, e; return t = namespace.use("Rollin.Casino.Dice.Dice"), e = function() { function e(t, e) { this.number = t, this.dice = e } return e.prototype.decimal = 5, e.prototype.getData = function(e, n, r) { var i, o, s, a, u; switch (r > t.MAX_NUMBER - 1 && (r = t.MAX_NUMBER - 1), r < t.MIN_NUMBER + 1 && (r = t.MIN_NUMBER + 1), i = this.dice.getFee(),n) {
  5. Hello Math Gods of phpfreaks. I am in need of a .... formula.... Let's inspect the outcomes.. As we can see, we have the BET SIZE (5), PREDICTION (88) which gives us our profits 40.01818 and 0.62727 So my question is: how do we get the Roll High Profits(40.01818), and Roll Low Profits(0.62727) from BET SIZE and PREDICTION? Anyone got a php function/formula for this? Or just a general math formula? (for a live example visit: https://rollin.io)
  6. I dont think this is working correctly. Im willing to paypal you some money if you could help a bit more. Skype: Lukecode
  7. Can you explain how I would use this in a while loop a bit? I added WHERE u.username = '$username' as well. for example: $row['m.message']; ?
  8. Here my code that will display all chat message groups and messages ORDERED BY when the group was created. I am trying to instead order the message_group list by last message received instead (exactly how imessage or any text message works) <?php $sql_messages = mysqli_query($connect, "SELECT DISTINCT group_id FROM message_group WHERE username = '$username' || recipients = '$username' ORDER BY id DESC;"); $num_messages = mysqli_num_rows($sql_messages); if($num_messages == 0){ ?> <div id="messagegroups"> <div align="center" style="padding: 5px;" id="nomsg">You have no messa
  9. <?php $sql_messages = mysqli_query($connect, "SELECT DISTINCT group_id FROM message_group WHERE username = '$username' || recipients = '$username' ORDER BY id DESC;"); $num_messages = mysqli_num_rows($sql_messages); if($num_messages == 0){ ?> <div id="messagegroups"> <div align="center" style="padding: 5px;" id="nomsg">You have no messages at this time.</div> <div id="messagegroupholder"> </div> <?php } else { ?> <div id="messagegroups"> <?php while($row_message
  10. I know that, but I have a sql query inside of another sql query, so how do I order by the 2nd query?
  11. Hey there, I am trying to order my messages by last message received instead of last message created. (Live Site if you want to try a live preview: https://snaps.im) send a message to: admin Here is how it is currently: Here is my mysql table: I basically need it to order exactly how imessages are stored on an iphone or phone.
  12. Actually, here's what I came up with (didnt include the quotes tho, didnt really understand a good way to do it.) <p>Quote of the day: <i>Don't watch the clock; do what it does. Keep going.</i></p> <?php $rowdates = mysqli_query($connect, "SELECT DISTINCT datestamp FROM links ORDER BY datestamp DESC"); $dates = array(); while($row = mysqli_fetch_assoc($rowdates)) { $dates[] = $row; } ?> <?php foreach($dates as $value) { ?> <h1><?php echo date('M d Y', strtotime($value['datestamp'])); ?></h1> <strong>Today's Links</stro
  13. Can you give me an example line of code for this? "you would then run a query that selects the data you want in the order that you want it. you would probably want a secondary sort order on the description so that the links are in alphabetical order within any date. you would fetch the data into a multi-dimensional array, using the date as the main array key/index. this will give you a sub-array of data for each date." Because I am confused if I need a foreach inside the while loop?
  14. $1000 for lifetime script access to a chatroom? Are you insane? lol
  15. Hello fine phpfreak members. I am having a brain cloud and cannot remember how to get these results out correctly. Here is my mysql table: And I need the data to show up like such: NOTE: I have a table called "quotes" with
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.