Jump to content

proxximo

Members
  • Posts

    48
  • Joined

  • Last visited

Everything posted by proxximo

  1. Thanks a ton. Setting a database variable to sold fixed it. Appreciated!
  2. This solution still allows the issue to persist. I tried in this form as well as creating a function and calling it onClick. Its driving me absolutely nuts! But thank you very much for a quick response _EmilsM!
  3. Hey Guys, I am creating a php text based game and during testing I have found a HUGE exploitable problem. During purchasing or selling items by clicking on a link (which then uses a MySQL query to updated the database), if you click the link multiple times before the next page loads you can sell one item multiple time, thus making quite a bit of in game currency really quickly. I have found a quick patch using javascript but it is not a solution I really want to stick with seeing as it uses an alert box... var clicked = false; function processClick() { if (clicked) return; clicked = true; alert("Your item has been sold"); } Basically I call the above function which stops them from clicking multiple times by popping an alert box. My question is... is there a better way to disable multiple clicks in this way, as I generally only like to use alert boxes for debugging and really slows down he pace of the game. Not to mention it looks terrible. Any help would be great. All of my google searches have left me with no clear alternative. Thanks! Proxximo
  4. Thanks for taking the time to respond Phailip. It is much appreiated!
  5. Hi there, I am the creator of a php, text based game. Recently we have gotten a composer to create some really great music for us, however with the game being set up as it currently is, that is to say click - page change, adding music is a little tricky. The advice I need is a solution for adding music that doesnt interrupt when the page changes. My first thought was to run the game in an iframe and have the music being played at html top level, but I am unsure if this is the best route to take, mostly because I would like to be able to change the music depending on what is happening in game (i.e. combat, visiting town, exploring, etc.) I was hoping to get some input before I move ahead with any solution. Does anyone know of a solution that would take cre of the following. -Does not interrupt the music when the page changes, as the scripts run constantly, changing the page to tell what your character is up to. -Can change the music from the php game -Keeps the interface clean Thanks a ton for your help guys and gals! If any more information is needed, I would be glad to give it. Proxximo
×
×
  • 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.