CN101901304A - Method for realizing intelligent algorithm for computer player in Doudizhu game - Google Patents

Method for realizing intelligent algorithm for computer player in Doudizhu game Download PDF

Info

Publication number
CN101901304A
CN101901304A CN201010246269XA CN201010246269A CN101901304A CN 101901304 A CN101901304 A CN 101901304A CN 201010246269X A CN201010246269X A CN 201010246269XA CN 201010246269 A CN201010246269 A CN 201010246269A CN 101901304 A CN101901304 A CN 101901304A
Authority
CN
China
Prior art keywords
recreation
card
landlord
player
intelligent algorithm
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201010246269XA
Other languages
Chinese (zh)
Inventor
郭昭何
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanghai Wingtech Electronic Technology Co Ltd
Original Assignee
SHANGHAI COOLBAR INFORMATION TECHNOLOGY Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by SHANGHAI COOLBAR INFORMATION TECHNOLOGY Co Ltd filed Critical SHANGHAI COOLBAR INFORMATION TECHNOLOGY Co Ltd
Priority to CN201010246269XA priority Critical patent/CN101901304A/en
Publication of CN101901304A publication Critical patent/CN101901304A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention discloses a method for realizing intelligent algorithm for a computer player in the Doudizhu game, which comprises the following steps of: (S1) randomly creating three gene banks, and permanently storing the data in the gene banks, wherein each group of gene bank is made up of chromosomes; (S2) after the game is started, selecting corresponding intelligent algorithm and chromosomes by the computer player according to different roles in the game; (S3) whenever in the computer player's turn to play a card, if the computer player can not play a card and select to pass, then jumping to S6; if the computer player can play a card, calculating all available card playing modes, and calculating the game situation after playing a card according to each card playing mode; (S4) scoring all the game situations obtained in S3; (S5) playing a card according to the card playing mode corresponding to the game situation with the highest score; (S6) whenever in the computer player's turn to play a card, repeating the steps from S3 to S5 and the steps from (S7) to (S9). The method enables the game to be more playable and entertaining.

Description

The implementation method of computer player intelligent algorithm in the fighting landlord recreation
Technical field
The present invention relates to a kind of mobile communication technology, particularly relate to the implementation method of computer player intelligent algorithm in a kind of fighting landlord recreation.
Background technology
Fighting landlord recreation is the type of the trying to be the first cards game that a three people play because its simple rule, lucid and lively rhythm and become a all-ages, the leisure game of fashionable network.But the strategy of playing a card of the computer player in the present most standalone version fighting landlord recreation is more single, is caught rule by the player easily, thereby greatly reduces the enjoyment of player to recreation.And for networking fighting landlord recreation, run into online number of players situation or the time period seldom sometimes, if the more virtual computer player of energy this moment are accompanied real player and are played, will significantly improve the popularity of recreation, just become the key of dealing with problems and how to make these computer player can simulate playing a card of real player.
Summary of the invention
In order to solve traditional fighting landlord computer player single, problem that degree of intelligence is low of strategy of playing a card, the invention provides the implementation method of computer player intelligent algorithm in a kind of fighting landlord recreation, make computer player can according to own in recreation the difference of identity of living in, take the different strategies of playing a card, and make this intelligent algorithm itself in game process, constantly to develop by means of genetic algorithm, produce the strategy of playing a card of intelligence more.Simultaneously because computer player can be learnt board in other staff by the mode of cheating, so that the strategy of playing a card of computer player will be more pointed.
The present invention solves above-mentioned technical matters by following technical proposals: the implementation method of computer player intelligent algorithm in a kind of fighting landlord recreation is characterized in that this method may further comprise the steps:
S1, produce three gene pools at random, every group of gene pool is made up of chromosome, and the data in the gene pool are carried out persistent storage;
After S2, the recreation beginning, computer player is according to different corresponding intelligent algorithm and the chromosomes chosen of residing role in recreation;
S3, take turns to computer player when playing a card at every turn,, jump to step S6 if can't play a card then selected board; Otherwise play a card, calculate all legal playing mode, and calculate the recreation situation after playing a card according to every kind of playing mode;
S4, all recreation situations that obtain among the step S3 are marked;
S5, play a card according to the playing mode of the highest recreation situation correspondence of score;
S6, whenever taking turns to when oneself playing a card repeated execution of steps S3 to S5;
After S7, the game over, the chromosome that uses in the local exchange recreation is marked;
S8, after the access times of certain gene pool surpass setting value, the minimum chromosome of score in the deletion gene pool, remaining chromosome is hybridized and made a variation, and chromosome number is amplified to original number, the chromosome number in the gene pool is remained unchanged;
S9, recreation in a single day restart repeated execution of steps S2 to S8.
Preferably, respectively corresponding three kinds of different intelligent algorithm types of described three gene pools.
Preferably, described three kinds of different intelligent algorithm types are landlord player, landlord's seller and the landlord player whose turn comes next.
Preferably, the data storage in the described gene pool is in database or file.
Preferably, will abide by recreation situation code of points to recreation situation scoring among the described step S4, recreation situation code of points comprises for landlord player's algorithm with for the landlord's seller and the landlord player whose turn comes next's algorithm.
Preferably, described step S7 abides by the rule of chromosome being marked after the game over to chromosome scoring.
Positive progressive effect of the present invention is: the algorithm of playing a card of computing machine of the present invention can obtain constantly progressive in recreation, makes the player feel more and more to have challenge in recreation, makes recreation have playability and recreational more.
Description of drawings
Fig. 1 is the process flow diagram of the implementation method of computer player intelligent algorithm in the fighting landlord recreation of the present invention.
Embodiment
Provide preferred embodiment of the present invention below in conjunction with accompanying drawing, to describe technical scheme of the present invention in detail.
As shown in Figure 1, the implementation method of computer player intelligent algorithm may further comprise the steps in the fighting landlord recreation of the present invention:
Step 1, produce three gene pools at random, the respectively corresponding three kinds of different intelligent algorithm types of these three gene pools, three kinds of different intelligent algorithm types are landlord player, landlord's seller and the landlord player whose turn comes next.Every group of gene pool is made up of S bar chromosome.Every ordered sequence (value of n can be different according to the algorithm specific implementation, gets n=10 in this example) that chromosome is n gene.Each gene is the floating number of value between 0 to 1, and promptly each chromosome can be expressed as { G1, G2, G3 to Gn}.Data in the gene pool are carried out persistent storage, can be put in the database or and preserve with document form.
After step 2, the recreation beginning, computer player is chosen corresponding intelligent algorithm and chromosome according to residing role in recreation is different, promptly chooses a chromosome and use in the local exchange recreation from corresponding gene pool.Write down the number of times that this gene pool was used at last.
Step 3, take turns to computer player when playing a card at every turn,, jump to step 6 if can't play a card then selected board.Otherwise play a card, calculate all legal playing mode, and calculate the recreation situation after playing a card according to every kind of playing mode, be about to board in the hand and deduct the board that oneself will go out.
Step 4, all recreation situations that obtain in the step 3 are marked.Code of points is referring to back described " recreation situation code of points ".
Step 5, play a card, promptly select the highest recreation situation of score, play a card, making recreation proceed to this kind situation according to its corresponding playing mode according to the playing mode of the highest recreation situation correspondence of score.
Step 6, whenever taking turns to when oneself playing a card, repeated execution of steps three is to step 5.
After step 7, the game over, the chromosome that uses in the local exchange recreation is marked.Code of points is referring to back described " rule of after the game over chromosome being marked ".This chromosomal total points (total points=former score+score in the local exchange recreation) is set at last, score information is carried out persistent storage.
Step 8, after the access times of certain gene pool surpass setting value K time, the minimum P% chromosome of score in the deletion gene pool is hybridized remaining chromosome, variation, and chromosome number is amplified to original number S, the chromosome number in the gene pool is remained unchanged.At last with the access times zero clearing of this gene pool.
Step 9, recreation in a single day restart, and repeated execution of steps two is to step 8.
Wherein, above-mentioned S, K, the value of P can constantly be adjusted with the debugging situation.
Recreation situation code of points comprises for landlord player's algorithm with for the landlord's seller and the landlord player whose turn comes next's algorithm, and is specific as follows:
For landlord player's algorithm, the score * G1+ of the board of recreation situation score=own suppose the score * that the player whose turn comes next beat the bridge queen who oneself has just gone out and remain board (G2)+suppose that seller beat score * that the bridge queen who oneself has just gone out remains board (G3);
For the landlord's seller and the landlord player whose turn comes next's algorithm, the score * G1+ hypothesis federation of the board of recreation situation score=own beat the bridge queen who oneself has just gone out and remained score * that bridge queen that the leading hypothetically mistake oneself of score * G2+ of board just gone out remains board (G3);
Wherein, when calculating " suppose seller/player whose turn comes next/landlord/federation beat the score that the bridge queen who oneself has just gone out remains board ",, then calculate the mean value of various situations if there is multiple mode to beat " board that oneself has just gone out ".If can't beat " board that oneself has just gone out ", then calculated the score of the board in bridge queen's hand.First three gene on the chromosome of choosing when the value of G1, G2, G3 corresponds respectively to the recreation beginning.
Code of points to board is as follows:
If the quantity of board is zero, then must be divided into best result.Otherwise count the score in such a way:
Trump card is according to continuous three, antithetical phrase continuously, and along son, three, antithetical phrase, the board type order of single board is divided into corresponding board type (continuous three, antithetical phrase can also continue segmentation along these board types of son continuously, only it is divided into 6 kinds in this example for convenience of description) successively.
The weights of this board type of quantity * of all boards in the weights summation of every one card/this board type in the score of each board type=this board type.
Wherein, the pairing weights of every one card are respectively:
Square/red heart/spade/showy flowers of herbaceous plants 3, weights are 3;
Square/red heart/spade/showy flowers of herbaceous plants 4, weights are 4;
Square/red heart/spade/showy flowers of herbaceous plants 5, weights are 5;
Square/red heart/spade/showy flowers of herbaceous plants 6, weights are 6;
Square/red heart/spade/showy flowers of herbaceous plants 7, weights are 7;
Square/red heart/spade/showy flowers of herbaceous plants 8, weights are 8;
Square/red heart/spade/showy flowers of herbaceous plants 9, weights are 9;
Square/red heart/spade/showy flowers of herbaceous plants 10, weights are 10;
Square/red heart/spade/showy flowers of herbaceous plants J, weights are 11;
Square/red heart/spade/showy flowers of herbaceous plants Q, weights are 12;
Square/red heart/spade/showy flowers of herbaceous plants K, weights are 13;
Square/red heart/spade/showy flowers of herbaceous plants A, weights are 14;
Square/red heart/spade/showy flowers of herbaceous plants 2, weights are 15;
Xiao Wang, weights are 16;
King, weights are 17;
The weights of board type are respectively:
Continuous three, G4;
Continuous antithetical phrase, G5;
Along son, G6;
Article three,, G7;
Antithetical phrase, G8;
Single board, G9;
Wherein, the gene of correspondence position in the corresponding selected chromosome of G4, G5 to G9 difference.If it is thinner that the board type divides, then can corresponding more gene.For convenience of description, this example is only selected the gene of 4 to 9 positions.
The score of board=(quantity of the score sum/board type of all board types)/(the quantity * Gn of board type).Wherein Gn is the gene of selected chromosomal last position.
The rule of after the game over chromosome being marked comprises the value of chromosome score and Y, and is specific as follows:
Chromosome score=Y-(during beginning in the hand weights sum of every board)/(during beginning in the hand number of board);
The value of Y: if the recreation triumph, Y=20; If failure game, Y=0.
Though more than described the specific embodiment of the present invention, it will be understood by those of skill in the art that these only illustrate, under the prerequisite that does not deviate from principle of the present invention and essence, can make numerous variations or modification to these embodiments.Therefore, protection scope of the present invention is limited by appended claims.

Claims (6)

1. the implementation method of computer player intelligent algorithm during a fighting landlord is played is characterized in that this method may further comprise the steps:
S1, produce three gene pools at random, every group of gene pool is made up of chromosome, and the data in the gene pool are carried out persistent storage;
After S2, the recreation beginning, computer player is according to different corresponding intelligent algorithm and the chromosomes chosen of residing role in recreation;
S3, take turns to computer player when playing a card at every turn,, jump to step S6 if can't play a card then selected board; Otherwise play a card, calculate all legal playing mode, and calculate the recreation situation after playing a card according to every kind of playing mode;
S4, all recreation situations that obtain among the step S3 are marked;
S5, play a card according to the playing mode of the highest recreation situation correspondence of score;
S6, whenever taking turns to when oneself playing a card repeated execution of steps S3 to S5;
After S7, the game over, the chromosome that uses in the local exchange recreation is marked;
S8, after the access times of certain gene pool surpass setting value, the minimum chromosome of score in the deletion gene pool, remaining chromosome is hybridized and made a variation, and chromosome number is amplified to original number, the chromosome number in the gene pool is remained unchanged;
S9, recreation in a single day restart repeated execution of steps S2 to S8.
2. the implementation method of computer player intelligent algorithm is characterized in that in the fighting landlord recreation as claimed in claim 1, the respectively corresponding three kinds of different intelligent algorithm types of described three gene pools.
3. the implementation method of computer player intelligent algorithm is characterized in that described three kinds of different intelligent algorithm types are landlord player, landlord's seller and the landlord player whose turn comes next in the fighting landlord recreation as claimed in claim 2.
4. the implementation method of computer player intelligent algorithm is characterized in that the data storage in the described gene pool is in database or file in the fighting landlord recreation as claimed in claim 1.
5. the implementation method of computer player intelligent algorithm in the fighting landlord recreation as claimed in claim 1, it is characterized in that, will abide by recreation situation code of points to recreation situation scoring among the described step S4, recreation situation code of points comprises for landlord player's algorithm with for the landlord's seller and the landlord player whose turn comes next's algorithm.
6. the implementation method of computer player intelligent algorithm is characterized in that the rule that described step S7 marks and in accordance with after the game over chromosome marked chromosome in the fighting landlord recreation as claimed in claim 1.
CN201010246269XA 2010-08-05 2010-08-05 Method for realizing intelligent algorithm for computer player in Doudizhu game Pending CN101901304A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201010246269XA CN101901304A (en) 2010-08-05 2010-08-05 Method for realizing intelligent algorithm for computer player in Doudizhu game

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201010246269XA CN101901304A (en) 2010-08-05 2010-08-05 Method for realizing intelligent algorithm for computer player in Doudizhu game

Publications (1)

Publication Number Publication Date
CN101901304A true CN101901304A (en) 2010-12-01

Family

ID=43226836

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201010246269XA Pending CN101901304A (en) 2010-08-05 2010-08-05 Method for realizing intelligent algorithm for computer player in Doudizhu game

Country Status (1)

Country Link
CN (1) CN101901304A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103838982A (en) * 2014-03-27 2014-06-04 优视科技有限公司 Virtual game object generating method and device
CN105664488A (en) * 2014-11-20 2016-06-15 博雅网络游戏开发(深圳)有限公司 Card game control method and system
CN109821228A (en) * 2019-03-07 2019-05-31 网易(杭州)网络有限公司 The object control method and device of chess/card game
CN110175619A (en) * 2018-11-27 2019-08-27 深圳市腾讯信息技术有限公司 Method, equipment and storage medium are determined based on the board group of playing a card of machine learning model
US20200258350A1 (en) * 2019-02-07 2020-08-13 Racing Reels Limited Electronic Gaming Machine
CN111729316A (en) * 2020-06-15 2020-10-02 北京智明星通科技股份有限公司 Card-out recommendation method and system in card battle game and game terminal

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20070043126A (en) * 2005-10-20 2007-04-25 (주)아라게이트 Artificial intelligence engine system for computer game
US20090158150A1 (en) * 2007-12-18 2009-06-18 International Business Machines Corporation Rules-based profile switching in metaverse applications
CN101732861A (en) * 2008-11-14 2010-06-16 康佳集团股份有限公司 Automatic card selecting method and system in electronic playing card game

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20070043126A (en) * 2005-10-20 2007-04-25 (주)아라게이트 Artificial intelligence engine system for computer game
US20090158150A1 (en) * 2007-12-18 2009-06-18 International Business Machines Corporation Rules-based profile switching in metaverse applications
CN101732861A (en) * 2008-11-14 2010-06-16 康佳集团股份有限公司 Automatic card selecting method and system in electronic playing card game

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
徐阳东等: "遗传算法在机器博弈中的创新应用", 《电脑知识与技术》 *
杨科选等: "遗传算法在游戏开发中的应用", 《计算机***应用》 *

Cited By (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103838982A (en) * 2014-03-27 2014-06-04 优视科技有限公司 Virtual game object generating method and device
CN103838982B (en) * 2014-03-27 2017-05-03 广州爱九游信息技术有限公司 Virtual game object generating method and device
CN105664488A (en) * 2014-11-20 2016-06-15 博雅网络游戏开发(深圳)有限公司 Card game control method and system
CN105664488B (en) * 2014-11-20 2019-06-14 博雅网络游戏开发(深圳)有限公司 The control method and system of Card Games
CN110175619B (en) * 2018-11-27 2023-02-03 深圳市腾讯信息技术有限公司 Method, device and storage medium for determining card-playing set based on machine learning model
CN110175619A (en) * 2018-11-27 2019-08-27 深圳市腾讯信息技术有限公司 Method, equipment and storage medium are determined based on the board group of playing a card of machine learning model
US11244534B2 (en) 2019-02-07 2022-02-08 Racing Reels Limited Electronic gaming machine
WO2020161513A1 (en) * 2019-02-07 2020-08-13 Racing Reels Limited Electronic gaming machine
US20200258350A1 (en) * 2019-02-07 2020-08-13 Racing Reels Limited Electronic Gaming Machine
US20220122411A1 (en) * 2019-02-07 2022-04-21 Racing Reels Limited Electronic Gaming Machine
US11727747B2 (en) * 2019-02-07 2023-08-15 Racing Reels Ltd Electronic gaming machine
CN109821228B (en) * 2019-03-07 2022-08-05 网易(杭州)网络有限公司 Object control method and device for chess and card game
CN109821228A (en) * 2019-03-07 2019-05-31 网易(杭州)网络有限公司 The object control method and device of chess/card game
CN111729316A (en) * 2020-06-15 2020-10-02 北京智明星通科技股份有限公司 Card-out recommendation method and system in card battle game and game terminal
CN111729316B (en) * 2020-06-15 2024-05-17 北京智明星通科技股份有限公司 Card playing recommendation method and system in card combat game and game terminal

Similar Documents

Publication Publication Date Title
Gilpin et al. A Texas Hold'em poker player based on automated abstraction and real-time equilibrium computation
US7704135B2 (en) Integrated game system, method, and device
US20180225919A1 (en) System and method for bet-matching and chance-element features for multi-player online skill games
US8740619B2 (en) Geography based card game and method of play
CN101901304A (en) Method for realizing intelligent algorithm for computer player in Doudizhu game
US20090036214A1 (en) Ranking System
Teytaud et al. Creating an upper-confidence-tree program for Havannah
Oikawa et al. Improving human players’ T-spin skills in Tetris with procedural problem generation
CN102272810A (en) Collectible centric educational game system
US20140110901A1 (en) Patent-Based Game Components
Haliem et al. Learning monopoly gameplay: A hybrid model-free deep reinforcement learning and imitation learning approach
Vieira et al. Reinforcement learning in collectible card games: Preliminary results on legends of code and magic
Beaudry et al. Using markov decision theory to provide a fair challenge in a roll-and-move board game
Conradie et al. Training bao game-playing agents using coevolutionary particle swarm optimization
Aung et al. Advantage of Initiative Revisited: A case study using Scrabble AI
Mayer et al. Coevolution of neural Go players in a cultural environment
Popyack Blackjack-playing agents in an advanced ai course
US20120302304A1 (en) Word flip game and app for smart phone and computer
US20180207525A1 (en) Method and game machine for playing multi-hand poker
US20170236449A1 (en) Educational card games and methods of play
CN107292389A (en) The formulating method and device of computer game strategy
Shishido et al. Alternating continuous Prisoner's Dilemma
US20140042698A1 (en) Method of Playing a Whirlwind Family Card Game
Lin League of legends match outcome prediction
US20220212089A1 (en) Pura Vida Monsters

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
ASS Succession or assignment of patent right

Owner name: SHANGHAI WENTAI ELECTRONIC SCIENCE + TECHNOLOGY CO

Free format text: FORMER OWNER: SHANGHAI COOLBAR INFORMATION TECHNOLOGY CO., LTD.

Effective date: 20130204

C41 Transfer of patent application or patent right or utility model
TA01 Transfer of patent application right

Effective date of registration: 20130204

Address after: 200001 6B01 room, G District, No. 666, Huangpu District, Shanghai, Beijing East Road

Applicant after: Shanghai Wentai Electronic Science & Technology Co., Ltd.

Address before: 200001, room 816, C District, No. 666, Huangpu District, Shanghai, Beijing East Road

Applicant before: Shanghai Coolbar Information Technology Co., Ltd.

C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20101201