Skip to content

Commit

Permalink
花牌数据类型改为uint8_t
Browse files Browse the repository at this point in the history
  • Loading branch information
summerinsects committed Dec 24, 2017
1 parent 15ff9cd commit 04763aa
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Classes/RecordSystem/RecordScene.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -884,7 +884,7 @@ void RecordScene::calculate(TilePickWidget *tilePicker, ExtraInfoWidget *extraIn
return;
}

temp.flower_count = extraInfo->getFlowerCount();
temp.flower_count = static_cast<uint8_t>(extraInfo->getFlowerCount());
if (temp.flower_count > 8) {
AlertView::showWithMessage("记录和牌", "花牌数的范围为0~8", 12, std::bind(&RecordScene::showCalculator, this, param), nullptr);
return;
Expand Down
2 changes: 1 addition & 1 deletion Classes/mahjong-algorithm/fan_calculator.h
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ int check_calculator_input(const hand_tiles_t *hand_tiles, tile_t win_tile);
struct calculate_param_t {
hand_tiles_t hand_tiles; ///< 手牌
tile_t win_tile; ///< 和牌张
int flower_count; ///< 花牌数
uint8_t flower_count; ///< 花牌数
win_flag_t win_flag; ///< 和牌标记
wind_t prevalent_wind; ///< 圈风
wind_t seat_wind; ///< 门风
Expand Down

0 comments on commit 04763aa

Please sign in to comment.