Mysidia Adoptables Support Forum

Mysidia Adoptables Support Forum (http://www.mysidiaadoptables.com/forum/index.php)
-   Questions and Supports (http://www.mysidiaadoptables.com/forum/forumdisplay.php?f=18)
-   -   Will pay for this.... (http://www.mysidiaadoptables.com/forum/showthread.php?t=3527)

SilverDragonTears 03-22-2012 06:10 PM

Will pay for this....
 
I want more excitement when clicking on pets. What I want is when you pull them from the database to show to a user for adoption, that some of them don't show up as often as the others, making them rare.

I will pay for someone to help me with this (Even Hof :P)

Serious inquiries only please.

!Alive 03-22-2012 06:30 PM

Could you explain in a more clear fashion exactly what you are trying to accomplish?
If I understand in the slightest you're wanting that when a user clicks on an adoptable they have a chance of finding/adopting an adoptable for their own. And that some of the prize adoptables are more rare to find. Right.
If this is kind of what you are wanting I may be able to help. I have a similar sort of random prize/adoptable getting system that works for me. There is just a random chance of stumbling across an adoptable just by browsing. It shouldn't be too hard to make so certain adoptables are more rare than others.

SilverDragonTears 03-22-2012 06:39 PM

Well not really, lol. But your idea may work. Can you explain your process a bit more?

!Alive 03-22-2012 06:57 PM

First I added a column to the (prefix)_adoptables table. With a numeric value, I suppose a text/varchar would work too. This number decides whether or not the adotpable is available to be found randomly. You should be able to use a differnt number for a rarity system.
Then I created a random prize php page that you are redirected to if you have found something. I modified the random secure adoption mod code from the mod section to fix what I wanted. Once I had that working a added a piece of code that randomly picks a number and if the number I choose is generated it links to the page. I have an additional variable that I added to prevent people from cheating to get the prize.
I think that's it in a nutshell. X3
So, what exactly are you trying to achieve?

SilverDragonTears 03-22-2012 07:15 PM

Well that went over my head!! lol

Ever played Dragon Cave? That's what I'm trying to do.. As you refresh the adoption page the adopts show up in threes randomly, and some of them don't pop us as often as the others....

Make better sense?

!Alive 03-22-2012 07:24 PM

Hasn't played Dragon Cave, but I think I better understand.

So on the actual page where you adopt pets from.(adopt.php) Show three random adoptables, some appearing less often than others.
That more like what you mean?

SilverDragonTears 03-22-2012 07:33 PM

Exactly what I mean :) Mine already show three at a time... but randomly... simply by using "LIMIT 3 RAND()" Doesn't help me to show some fewer times than others.

!Alive 03-22-2012 07:43 PM

Well then you could set up a column in your adoptables table for rarity. You could use numbers, text, or varchar. In numbers different rarities would be numbers like 1,2,or 3. Or with text/varchar it could actually be labeled common, uncommon, rare, ect. Then you would run a random number to select a query that would pull the rarity from the adoptable table, randomize which to choose and show it to the user. Do this for each adoptable you wish to show.

Something like that should work. I think I should go play with this to see if I can make it work for me before trying to present any code.

SilverDragonTears 03-22-2012 07:53 PM

I would love to have the code if it works!!

!Alive 03-22-2012 08:33 PM

Okay so I got the rarity thing working pretty easily. But I only have it showing one adoptable. I could have it show three but with what I have it would show three of the same rarity. I'm still trying to come up with a way to run it so that it will work with 3.


All times are GMT -5. The time now is 01:55 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.