diff options
author | Iru Cai <mytbk920423@gmail.com> | 2018-09-23 21:31:33 +0800 |
---|---|---|
committer | Iru Cai <mytbk920423@gmail.com> | 2018-09-23 21:31:33 +0800 |
commit | 6e0dd28c50e35790555892df5cb280b5b2b9d4f7 (patch) | |
tree | c508a22a65b29414695357c689b00b8955f93417 | |
parent | 3680eaeddd230bf4bb7f63402973b9255323e6ad (diff) | |
download | rich4-6e0dd28c50e35790555892df5cb280b5b2b9d4f7.tar.xz |
stop card
-rw-r--r-- | csrc/cards.c | 39 | ||||
-rw-r--r-- | csrc/player_action.c | 3 |
2 files changed, 40 insertions, 2 deletions
diff --git a/csrc/cards.c b/csrc/cards.c index bffd2d9..909c054 100644 --- a/csrc/cards.c +++ b/csrc/cards.c @@ -904,6 +904,44 @@ int angel_card() return ebp; } +int stop_card() +{ + if (players[current_player].who_plays == 1) { + edi = fcn.00446ae8(0xe0c0010); + } else { + edi = fcn.0041e6f2(0); + } + + if (edi != 0) { + selected_player = fcn.0040d293(edi); + consume_a_card(current_player, 14); + if (selected_player != current_player) { + int c = players[current_player].character; + player_say(current_player, 3, card_strings[c][0][13]); + } + if (players[current_player].who_plays != 1) { + sub.WINMM.dll_timeGetTime_669(0, + players[current_player].f8, players[current_player].f10, + players[selected_player].f8, players[selected_player].f10, 100); + } + if (selected_player < 4) { + if (selected_player == current_player) { + int c = players[current_player].character; + player_say(current_player, 3, card_strings[c][1][13]); + players[current_player].days_stopping = 0x80; + } else { + int c = players[selected_player].character; + player_say(current_player, 2, card_strings[c][2][13]); + players[selected_player].days_stopping = 1; + fcn_41d546(); + } + } else { + special_players[selected_player].days_stopping = 1; + } + } + return edi; +} + int tortoise_walking_card() { if (players[current_player].who_plays == 1) { @@ -914,7 +952,6 @@ int tortoise_walking_card() if (edi == 0) return 0; - esi = ebx = fcn.0040d293(edi); int selected_player = fcn.0040d293(edi); consume_a_card(current_player, 30); ebp = current_player; diff --git a/csrc/player_action.c b/csrc/player_action.c index e0d349e..27fe977 100644 --- a/csrc/player_action.c +++ b/csrc/player_action.c @@ -23,7 +23,8 @@ typedef struct uint16_t f2; uint16_t f4; uint16_t f6; - uint8_t f8[7]; + uint8_t f8[6]; + uint8_t days_stopping; uint8_t days_tortoise_walking; } special_player_info; |