php - Making a Pyramids card game, unsure of how to setup the pyramid -
I generally do not make a game in PHP, I usually only do the website but I first created a card game in PHP is .
This time I wanted to try a pyramid solitaire game because I love playing it.
I started the pyramid (the front row below,
example:
I used pyramid for loops and it Everyone sets well, but my problem is it is not certain how to check to see if I need it or need a new card.
I have usually found out how things work, but it is stumped. < / P>
This is for the loop for the bottom line of the 10 shown cards. ($ Deck is an array of ready shafed decks.)
for ($ i = 0; $ I & lt; 10; $ i ++) {$ card = array_shift ($ deck); resonate "div style = 'position: full; top:". $ Card_lvl_1t. "Left:" $ card_lvl_1l . ", Width: 55px; height: 90px; '& gt; & lt; img src ='". $ Card. "'Border =' 0 '& gt; & quot; / div & gt; \ n"; $ Card_lvl_1l = $ card_lvl_1l + 56;}
Any suggestions would be very welcome.
Sorry if this post is a little confusing or well written Damage is not, but basically all that I am asking advice will do.
Thanks
Sorry if my thoughts are not complete, but I How to go in and at a high level on how everything will be handled.
I will not use php only, jQuery will also be included in it. The basic gameplay is that two cards are equal to 13 and then they remove if the card is removed completely, then the card shows. Do not forget about plus garbage and pull pile. JQuery will call PHP and PHP as JSAN.
PHP
Game Class (OOP) | - Start the randomization of the cards in the pyramid and attract the heap. - Draw Stacks | | | - Put the card in the pile drawn in order to call it. - Waste Stack. | - Call the card to put in the waste pile. - Evaluate the card (Card 1, Card 2). | - Sometimes a card can be (king). | - It will evaluate whether they are equal to 13 and if they are removed. | - If fully open, call to check the card (possibly each card will be covered with 1 or 2 (1 card will be removed, then cover will be 0.5 or 1). - Successful. Remove the card from the deck variable | - JSON to remove the return card and flip the card X (if the value is not already, pass the card face value). | - Evaluate the evaluation card | | - Check to see if the card Is completely open and The card is used by the above mentioned card. - Card card value | | - This card will return face value. - Ex: King of the heart can be KH, H13 or similar. - Score | | - Self explanatory, but if you want to score It is used to keep. | - Card invention | | - Self explanatory
Of course there will be variables that will keep any information about pyramids, draws, and piles or card information.
JQuery
In this Include styled game setup, play, and output.
Click Track 2 clicks in a row (??) in the same device | | - The same card | | | - Was a heap or pyramid card - Do nothing. | | - Drag the stack - Step card to ruin the heap. | | | - Call AJAX to move cards from Draw - & gt; Waste | | - different card | | - Click highlight card. | | - Call AXX to check the value in PHP file. | | - If you are successful in removing the cards, then display the available card. | - Update Score | - Controllers who do not require 2 clicks. - The card is a king. | - New game | | - Attract the pile button to ruin it. | - etc ....
Comments
Post a Comment