Thread: Vote4cash claim

Page 1 of 2 12 LastLast
Results 1 to 10 of 12
  1. #1 Vote4cash claim 
    Registered Member
    Join Date
    Dec 2011
    Posts
    177
    Thanks given
    11
    Thanks received
    16
    Rep Power
    20
    I finally got my vote4cash up but after i enter the username and vote when I try doing ::claim it just doesnt work. its says I havent voted. Anyone have an idea how I could fix this?
    Reply With Quote  
     

  2. #2  
    Registered Member White Wolf's Avatar
    Join Date
    Apr 2012
    Posts
    66
    Thanks given
    0
    Thanks received
    4
    Rep Power
    11
    Any potentially useful output? I'm assuming this is being done through a database or web API so I would guess it has to do with a value either not being correctly changed or not being read properly. Without any other information there isn't much of anything anyone can do to help you.
    Reply With Quote  
     

  3. #3  
    Registered Member
    Join Date
    Dec 2011
    Posts
    177
    Thanks given
    11
    Thanks received
    16
    Rep Power
    20
    I used mysql for this
    Reply With Quote  
     

  4. #4  
    Registered Member White Wolf's Avatar
    Join Date
    Apr 2012
    Posts
    66
    Thanks given
    0
    Thanks received
    4
    Rep Power
    11
    Did you follow a tutorial for this? If so could you link me to it? If not I'd like to see your claim command code as well as any SQL queries. Is your database properly set up? Do you have the correct administrator information? Etc.?
    Reply With Quote  
     

  5. #5  
    Donator


    Join Date
    Aug 2010
    Posts
    3,174
    Thanks given
    1,724
    Thanks received
    2,002
    Rep Power
    3837
    Quote Originally Posted by pkmoney View Post
    I used mysql for this
    whats you claim command?

    Make sure its something like this:
    Code:
    			if (playerCommand.equals("claimvote")) {
    if(c.checkVotes(c.playerName)) {
                                    c.getItems().addItem(995, 5000000);
                                    c.sendMessage("Thanks for voting!");
                            } else {
    c.sendMessage("You didn't vote!");
    }
    					}
    Reply With Quote  
     

  6. #6  
    Registered Member White Wolf's Avatar
    Join Date
    Apr 2012
    Posts
    66
    Thanks given
    0
    Thanks received
    4
    Rep Power
    11
    Just simply "it doesn't work" could mean a very very broad number of things. A little more information would be useful, code in particular.
    Reply With Quote  
     

  7. #7  
    Registered Member
    Join Date
    Dec 2011
    Posts
    177
    Thanks given
    11
    Thanks received
    16
    Rep Power
    20
    Well everything works. Like all the accounts usernames and ips are IN the database. Everything is working fine EXCEPT for some reason after someone types their usernames and votes it says they HAVENT voted :L
    Reply With Quote  
     

  8. #8  
    Registered Member White Wolf's Avatar
    Join Date
    Apr 2012
    Posts
    66
    Thanks given
    0
    Thanks received
    4
    Rep Power
    11
    Show me the claim command code.
    Reply With Quote  
     

  9. #9  
    Registered Member
    Join Date
    Dec 2011
    Posts
    177
    Thanks given
    11
    Thanks received
    16
    Rep Power
    20
    Code:
    				if (playerCommand.startsWith("claim"))
    				{
    					if(c.checkVotes(c.playerName)) {
    						if(c.getItems().freeSlots() > 0) {
    							c.getItems().addItem(7774, 5);
    							c.sendMessage("Thank you for voting");
    						} else {
    							c.sendMessage("You do not have enough free space to receive your voting reward.");
    						}
    					} else {
    					c.sendMessage("You have not voted yet!");
    					}
    				}
    Reply With Quote  
     

  10. #10  
    Registered Member White Wolf's Avatar
    Join Date
    Apr 2012
    Posts
    66
    Thanks given
    0
    Thanks received
    4
    Rep Power
    11
    So the problem must be within the checkVotes method or methods called by it.
    Reply With Quote  
     

Page 1 of 2 12 LastLast

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. [PI] Vote4Cash ::Claim Command
    By owner will in forum Help
    Replies: 3
    Last Post: 07-18-2012, 05:43 PM
  2. Need Help With ::claim
    By Nuno555 in forum Help
    Replies: 8
    Last Post: 01-22-2012, 03:51 AM
  3. vote4cash claim command [562]
    By iSacred in forum Help
    Replies: 37
    Last Post: 07-11-2011, 03:16 PM
  4. [PI] ::claim help
    By Killznodie in forum Help
    Replies: 5
    Last Post: 05-04-2011, 09:29 AM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •