MCPcopy Create free account

hub / github.com/blovemaple/mahjong / functions

Functions695 in github.com/blovemaple/mahjong

↓ 3 callersMethodgetPlayerInfo
()
src/main/java/com/github/blovemaple/mj/local/barbot/BarBotCpgdChoice.java:271
↓ 3 callersMethodgetTileWallSize
返回牌墙中的剩余牌数。
src/main/java/com/github/blovemaple/mj/object/MahjongTablePlayerView.java:25
↓ 3 callersMethodgetTimeLimitStrategy
()
src/main/java/com/github/blovemaple/mj/game/GameContext.java:24
↓ 3 callersMethodgetWinTile
()
src/main/java/com/github/blovemaple/mj/game/GameResult.java:41
↓ 3 callersMethodid
返回ID,同一牌型从0开始,通常是[0,3]。
src/main/java/com/github/blovemaple/mj/object/Tile.java:71
↓ 3 callersMethodisJiang
()
src/main/java/com/github/blovemaple/mj/local/bazbot/BazBotTileUnit.java:53
↓ 3 callersMethodmeetPrecondition
判断当前状态下指定玩家是否符合做出此类型动作的前提条件(比如“碰”的前提条件是别人刚出牌)。<br> 默认实现调用相应方法对上一个动作和活牌数量进行限制,进行判断。
src/main/java/com/github/blovemaple/mj/action/AbstractPlayerActionType.java:49
↓ 3 callersMethodnewBranchOrResult
(ParseBranch baseBranch, List<Tile> selectedTiles, TileUnitType newUnitType, Queue<ParseBranch> branchQueu
src/main/java/com/github/blovemaple/mj/rule/simple/NormalWinType.java:191
↓ 3 callersMethodof
(boolean completed, StandardTileUnitType unitType, Set<Tile> tiles)
src/main/java/com/github/blovemaple/mj/local/bazbot/BazBotTileUnit.java:57
↓ 3 callersMethodrethrowFunction
( Function_WithExceptions<T, R, E> function)
src/main/java/com/github/blovemaple/mj/utils/LambdaUtils.java:64
↓ 3 callersMethodsetContextView
(GameContextPlayerView contextView)
src/main/java/com/github/blovemaple/mj/rule/win/WinInfo.java:82
↓ 3 callersMethodshowActionDefault
(Action action)
src/main/java/com/github/blovemaple/mj/cli/CliGameView.java:406
↓ 3 callersMethodviewFocusAndOptions
()
src/main/java/com/github/blovemaple/mj/cli/CliPlayer.java:285
↓ 2 callersMethodactionDone
(Action action)
src/main/java/com/github/blovemaple/mj/game/GameContext.java:36
↓ 2 callersMethodaddCharHandler
添加一个字符处理器。添加后,读取的所有字符都将交给此字符处理器处理。 @param handler 字符处理器 @param wait 是否等待,直到此监听器停止监听(被移除),此方法才返回 @throws InterruptedException
src/main/java/com/github/blovemaple/mj/cli/CliView.java:153
↓ 2 callersMethodaliveTilesStr
()
src/main/java/com/github/blovemaple/mj/local/barbot/BarBotCpgdSelectTask.java:65
↓ 2 callersMethodall
返回所有144张牌的列表。
src/main/java/com/github/blovemaple/mj/object/Tile.java:32
↓ 2 callersMethodappendGroups
(StringBuilder str)
src/main/java/com/github/blovemaple/mj/cli/CliGameView.java:143
↓ 2 callersMethodcanDo
判断指定状态下指定位置的玩家可否做此种类型的动作。 @return 能做返回true;否则返回false。
src/main/java/com/github/blovemaple/mj/action/PlayerActionType.java:23
↓ 2 callersMethodcanPass
返回此动作是否可以放弃。 @return 可以放弃返回true;否则返回false。
src/main/java/com/github/blovemaple/mj/action/PlayerActionType.java:30
↓ 2 callersMethodcanWin
判断指定条件下是否可和牌。<br> 默认实现为使用此策略支持的所有和牌类型进行判断,至少有一种和牌类型判断可以和牌则可以和牌。
src/main/java/com/github/blovemaple/mj/rule/GameStrategy.java:85
↓ 2 callersMethodchangingsForWin
用于机器人,获取ChangingForWin的流,移除changeCount个牌,增加(changeCount+1)个牌。
src/main/java/com/github/blovemaple/mj/rule/win/WinType.java:49
↓ 2 callersMethodcombCount
(long total, int select)
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:418
↓ 2 callersMethodcombStreamGreedy
返回指定集合中符合条件的尽量多的元素组合组成的流。 @param coll 指定集合 @param combCollFactory 新建集合对象的函数,用于新建元素组合使用的集合 @param condition 一个组合中的任意两
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:134
↓ 2 callersMethoddistinctCollBy
将指定的集合流按照标识符去重。标识符用指定的函数获取。 @param stream 集合流 @param identifierFunction 获取标识符的函数 @return 去重后的集合流
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:366
↓ 2 callersMethodfindLegalPengGroup
返回在玩家的牌中能与动作牌组成补杠的碰组(Optional)。
src/main/java/com/github/blovemaple/mj/action/standard/BugangActionType.java:76
↓ 2 callersMethodfireEvent
(GameContext context, BiConsumer<Player, GameContextPlayerView> consumer)
src/main/java/com/github/blovemaple/mj/game/MahjongGame.java:353
↓ 2 callersMethodfixedWidth
如果str不够指定长度,则在后面补空格。
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:409
↓ 2 callersMethodgenChangingsBySelectedUnits
(List<PreUnit> preUnits, List<Tile> aliveTiles, Map<TileType, List<Tile>> candidatesByType)
src/main/java/com/github/blovemaple/mj/rule/simple/NormalWinType.java:461
↓ 2 callersMethodget
()
src/main/java/com/github/blovemaple/mj/rule/simple/NormalWinType.java:49
↓ 2 callersMethodgetActionTilesRange
返回合法动作中相关牌的可选范围。<br> 默认实现为指定玩家的aliveTiles。
src/main/java/com/github/blovemaple/mj/action/AbstractPlayerActionType.java:172
↓ 2 callersMethodgetActionTilesSize
返回合法动作中相关牌的数量。可以为0。
src/main/java/com/github/blovemaple/mj/action/AbstractPlayerActionType.java:179
↓ 2 callersMethodgetDiscardCandidates
用于机器人,返回建议打出的牌,即从手牌中排除掉明显不应该打出的牌并返回。返回的列表按建议的优先级从高到低排列。
src/main/java/com/github/blovemaple/mj/rule/win/WinType.java:44
↓ 2 callersMethodgetFans
()
src/main/java/com/github/blovemaple/mj/game/GameResult.java:57
↓ 2 callersMethodgetFans
算番。 @param winInfo 被检查的牌 @param fanTypes 使用的番种 @param winTypes 使用的和牌类型 @return 符合的番种和番数
src/main/java/com/github/blovemaple/mj/rule/win/FanType.java:42
↓ 2 callersMethodgetGotTile
返回得牌。类型为暗杠时返回null。 @return 得牌
src/main/java/com/github/blovemaple/mj/object/TileGroupPlayerView.java:40
↓ 2 callersMethodgetNextStageName
()
src/main/java/com/github/blovemaple/mj/action/StageSwitchAction.java:19
↓ 2 callersMethodgetPlayerByLocation
(PlayerLocation location)
src/main/java/com/github/blovemaple/mj/object/MahjongTable.java:112
↓ 2 callersMethodgetPlayerInfoView
返回PlayerInfo视图。
src/main/java/com/github/blovemaple/mj/object/MahjongTablePlayerView.java:40
↓ 2 callersMethodgetStageByName
根据阶段名称返回阶段。
src/main/java/com/github/blovemaple/mj/rule/GameStrategy.java:44
↓ 2 callersMethodgetType
()
src/main/java/com/github/blovemaple/mj/object/TileGroup.java:114
↓ 2 callersMethodgetWinInfo
()
src/main/java/com/github/blovemaple/mj/local/barbot/BarBotSimChanging.java:45
↓ 2 callersMethodgetWinPoint
()
src/main/java/com/github/blovemaple/mj/local/barbot/BarBotSimChanging.java:58
↓ 2 callersMethodgetWinnerLocation
()
src/main/java/com/github/blovemaple/mj/game/GameResult.java:33
↓ 2 callersMethodgot
(TileUnitType type, Collection<Tile> tiles, Tile gotTile)
src/main/java/com/github/blovemaple/mj/object/TileUnit.java:30
↓ 2 callersMethodhandle
(CharHandler handler, char c)
src/main/java/com/github/blovemaple/mj/cli/CliView.java:259
↓ 2 callersMethodinit
初始化显示。 @throws IOException
src/main/java/com/github/blovemaple/mj/cli/CliView.java:65
↓ 2 callersMethodinit
()
src/main/java/com/github/blovemaple/mj/object/MahjongTable.java:35
↓ 2 callersMethodinitParseUnits
()
src/main/java/com/github/blovemaple/mj/local/bazbot/BazBotTileNeighborhood.java:104
↓ 2 callersMethodisLegalActionTiles
判断动作是否合法。<br> 默认实现为:先检查前提条件、相关牌数量、相关牌范围,如果满足再调用{@link #isLegalActionWithPreconition}。
src/main/java/com/github/blovemaple/mj/action/AbstractPlayerActionType.java:185
↓ 2 callersMethodisLegalTilesWithCorrectSize
(Collection<Tile> tiles)
src/main/java/com/github/blovemaple/mj/object/StandardTileUnitType.java:27
↓ 2 callersMethodisNeighbors
(Tile tile1, Tile tile2)
src/main/java/com/github/blovemaple/mj/local/bazbot/BazBotTileNeighborhood.java:70
↓ 2 callersMethodlegalActionTilesStream
返回一个流,流中包含指定状态下指定玩家可作出的此类型的所有合法动作的相关牌集合。<br> 默认实现为:在玩家手中的牌中选取所有合法数量个牌的组合,并使用{@link #isLegalActionTiles}过滤出合法的组合。<br> 如果合法的相关牌不限于手中的牌,则需要子类重写此方法。
src/main/java/com/github/blovemaple/mj/action/AbstractPlayerActionType.java:158
↓ 2 callersMethodmoveFocusChoice
(boolean forward)
src/main/java/com/github/blovemaple/mj/cli/CliPlayer.java:251
↓ 2 callersMethodofName
(String name)
src/main/java/com/github/blovemaple/mj/utils/LanguageManager.java:100
↓ 2 callersMethodparsePreShunkes
(List<Tile> aliveTiles, Map<TileSuit, List<Tile>> candidatesBySuit)
src/main/java/com/github/blovemaple/mj/rule/simple/NormalWinType.java:314
↓ 2 callersMethodparseWinTileUnits
全部解析成可以和牌的完整的TileUnit集合的列表并填入和牌信息并返回,失败填入并返回空列表。 @param winInfo 和牌信息
src/main/java/com/github/blovemaple/mj/rule/win/WinType.java:26
↓ 2 callersMethodplay
进行一局麻将游戏,结束后返回结果。 @return 结果 @throws InterruptedException 等待玩家做出选择的时候当前线程被中断
src/main/java/com/github/blovemaple/mj/game/MahjongGame.java:62
↓ 2 callersMethodpreShunkesStreamGreedy
(List<PreUnit> preShunkes, int forCount)
src/main/java/com/github/blovemaple/mj/rule/simple/NormalWinType.java:417
↓ 2 callersMethodremainColl
将指定的一个集合中的元素减去指定元素产生一个新的集合并返回。
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:314
↓ 2 callersMethodrun
()
src/main/java/com/github/blovemaple/mj/cli/CliRunner.java:51
↓ 2 callersMethodsetGameResult
(GameResult gameResult)
src/main/java/com/github/blovemaple/mj/game/GameContext.java:46
↓ 2 callersMethodsetLastDrawedTile
(Tile lastDrawedTile)
src/main/java/com/github/blovemaple/mj/object/PlayerInfo.java:44
↓ 2 callersMethodsetUnits
(WinType winType, List<List<TileUnit>> units)
src/main/java/com/github/blovemaple/mj/rule/win/WinInfo.java:108
↓ 2 callersMethodsetWinTile
(Tile winTile)
src/main/java/com/github/blovemaple/mj/game/GameResult.java:45
↓ 2 callersMethodshowAction
(Action action)
src/main/java/com/github/blovemaple/mj/cli/CliGameView.java:273
↓ 2 callersMethodtypeDistinctStream
(Collection<Tile> tiles, int size)
src/main/java/com/github/blovemaple/mj/local/barbot/BarBotCpgdChoice.java:251
↓ 2 callersMethodunits
()
src/main/java/com/github/blovemaple/mj/local/bazbot/BazBotTileUnits.java:58
↓ 1 callersMethodafterSimAction
模拟执行指定动作,并返回新的实例。模拟动作在新实例上执行,不改变本实例的状态。 @param action 模拟执行的动作 @return 执行完动作的新实例。如果模拟动作为放弃(null),则直接返回当前实例。
src/main/java/com/github/blovemaple/mj/local/bazbot/BazBotSimContext.java:74
↓ 1 callersMethodaliveTilesStr
(GameContextPlayerView contextView)
src/main/java/com/github/blovemaple/mj/local/AbstractBot.java:118
↓ 1 callersMethodall
返回所有牌型的列表。
src/main/java/com/github/blovemaple/mj/object/TileType.java:42
↓ 1 callersMethodallChoices
()
src/main/java/com/github/blovemaple/mj/local/barbot/BarBotCpgdSelectTask.java:135
↓ 1 callersMethodallCombs
挑选符合数量要求的unit组合,返回所有的可能。<br> 先找到第一个unit,然后返回以下结果: <li>把数量要求减1、去除与第一个unit冲突者,并递归调用,最后把第一个unit和递归调用的结果分别拼接; <li>按照原数量要求,从所有剩余unit中递归获取结果。 @param maxUni
src/main/java/com/github/blovemaple/mj/local/bazbot/BazBotTileUnits.java:89
↓ 1 callersMethodallOfType
返回指定牌型的所有牌的集合。
src/main/java/com/github/blovemaple/mj/object/Tile.java:39
↓ 1 callersMethodappendOptions
(StringBuilder str)
src/main/java/com/github/blovemaple/mj/cli/CliGameView.java:250
↓ 1 callersMethodappendTimeLimit
(StringBuilder str)
src/main/java/com/github/blovemaple/mj/cli/CliGameView.java:265
↓ 1 callersMethodappendTingStatus
(StringBuilder str)
src/main/java/com/github/blovemaple/mj/cli/CliGameView.java:242
↓ 1 callersMethodbazBotAliveTilesTest
()
src/test/java/com/github/blovemaple/mj/local/bazbot/BazBotTest.java:17
↓ 1 callersMethodcalcProb
(Collection<TileType> tileTypes)
src/main/java/com/github/blovemaple/mj/local/bazbot/BazBotSimContext.java:159
↓ 1 callersMethodcanDoWithPrecondition
判断指定状态下指定位置的玩家可否做此种类型的动作。调用此方法之前已经使用{@link #meetPrecondition}判断过符合前提条件。 <br> 默认实现为:判断{@link #legalActionTilesStream}返回的流不为空。
src/main/java/com/github/blovemaple/mj/action/AbstractPlayerActionType.java:104
↓ 1 callersMethodcheckReady
检查一个麻将桌是否符合条件开始进行一局。 @param table 麻将桌 @return 如果可以开始,返回true,否则返回false。
src/main/java/com/github/blovemaple/mj/rule/GameStrategy.java:34
↓ 1 callersMethodchooseAction
决定要执行的动作。先让stage和玩家选择,如果无可选动作或者都选择不做动作,则从stage获取默认动作。
src/main/java/com/github/blovemaple/mj/game/MahjongGame.java:135
↓ 1 callersMethodchooseAction0
(GameContextPlayerView contextView, Set<PlayerActionType> actionTypes)
src/main/java/com/github/blovemaple/mj/local/AbstractBot.java:83
↓ 1 callersMethodchooseAndDoAction
在指定的状态下执行一步动作。 @return 有没有执行动作 @throws InterruptedException
src/main/java/com/github/blovemaple/mj/game/MahjongGame.java:114
↓ 1 callersMethodchooseCpgdAction
(GameContextPlayerView contextView, Set<PlayerActionType> actionTypes, List<PlayerAction> actions)
src/main/java/com/github/blovemaple/mj/local/AbstractBot.java:164
↓ 1 callersMethodchooseCpgdActionWithTimer
(GameContextPlayerView contextView, Set<PlayerActionType> actionTypes, List<PlayerAction> actions)
src/main/java/com/github/blovemaple/mj/local/AbstractBot.java:150
↓ 1 callersMethodclasses
从包package中获取所有的Class。<br> 来源:http://lushuifa.iteye.com/blog/1972847
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:439
↓ 1 callersMethodcleanPreUnits
(List<PreUnit> preJiangs, List<PreUnit> preShunkes)
src/main/java/com/github/blovemaple/mj/rule/simple/NormalWinType.java:346
↓ 1 callersMethodcombSetStream
返回指定集合中指定个数的元素组合(HashSet)组成的流。 @param coll 指定集合 @param size 组合中的元素个数 @return 组合Set的流
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:47
↓ 1 callersMethodcombStreamGreedy0
@param coll @param limit @param combCollFactory @param selected 当前递归分支的已选元素 @param conflictsMap 所有元素 - 与之冲突的元素集合 @param checkPoi
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:202
↓ 1 callersMethodcompete
(int gameCount)
src/main/java/com/github/blovemaple/mj/botcompetition/BotCompetition.java:39
↓ 1 callersMethodcpgdActions
(GameContextPlayerView contextView, Set<PlayerActionType> actionTypes)
src/main/java/com/github/blovemaple/mj/local/AbstractBot.java:126
↓ 1 callersMethoddetermineAction
(Map<PlayerLocation, Set<PlayerActionType>> choicesByLocation, Map<PlayerLocation, PlayerAction> choseActi
src/main/java/com/github/blovemaple/mj/game/MahjongGame.java:292
↓ 1 callersMethoddisjointBy
判断指定两个集合中的元素是否没有任何标识符重复。标识符用指定的函数获取。 @param c1 集合1 @param c2 集合2 @param identifierFunction 获取标识符的函数 @return 没有重复返回tr
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:386
↓ 1 callersMethoddoAction
(GameContext context, Action action)
src/main/java/com/github/blovemaple/mj/game/MahjongGame.java:347
↓ 1 callersMethoddoAction
(GameContextPlayerView baseContextView, PlayerInfo baseInfo, PlayerAction action)
src/main/java/com/github/blovemaple/mj/local/barbot/BarBotCpgdChoice.java:74
↓ 1 callersMethoddoLegalAction
执行动作。调用此方法之前已经确保符合动作类型,并使用{@link #isLegalActionTiles}判断过动作的合法性。
src/main/java/com/github/blovemaple/mj/action/AbstractPlayerActionType.java:216
↓ 1 callersMethoddrawBottom
从牌墙的底部摸指定数量的牌并返回。
src/main/java/com/github/blovemaple/mj/object/MahjongTable.java:93
↓ 1 callersMethodfindAndAddClassesInPackageByFile
以文件的形式来获取包下的所有Class。<br> 来源:http://lushuifa.iteye.com/blog/1972847 @param packageName @param packagePath @param recursive @param classes
src/main/java/com/github/blovemaple/mj/utils/MyUtils.java:529
↓ 1 callersMethodforEachHoodAndUnits
(BiConsumer<BazBotTileNeighborhood, List<BazBotTileUnit>> action)
src/main/java/com/github/blovemaple/mj/local/bazbot/BazBotTileUnits.java:62
← previousnext →101–200 of 695, ranked by callers