Commit 84ae6622 authored by 不如归去's avatar 不如归去 Committed by GitHub

Delay special init to make start_lp visible (#16)

parent 5879e2c7
...@@ -554,11 +554,11 @@ void SingleDuel::TPResult(DuelPlayer* dp, unsigned char tp) { ...@@ -554,11 +554,11 @@ void SingleDuel::TPResult(DuelPlayer* dp, unsigned char tp) {
set_card_reader(DataManager::CardReader); set_card_reader(DataManager::CardReader);
set_message_handler(SingleDuel::MessageHandler); set_message_handler(SingleDuel::MessageHandler);
pduel = create_duel(duel_seed); pduel = create_duel(duel_seed);
set_player_info(pduel, 0, host_info.start_lp, host_info.start_hand, host_info.draw_count);
set_player_info(pduel, 1, host_info.start_lp, host_info.start_hand, host_info.draw_count);
#ifdef YGOPRO_SERVER_MODE #ifdef YGOPRO_SERVER_MODE
preload_script(pduel, "./script/special.lua", 0); preload_script(pduel, "./script/special.lua", 0);
#endif #endif
set_player_info(pduel, 0, host_info.start_lp, host_info.start_hand, host_info.draw_count);
set_player_info(pduel, 1, host_info.start_lp, host_info.start_hand, host_info.draw_count);
int opt = (int)host_info.duel_rule << 16; int opt = (int)host_info.duel_rule << 16;
if(host_info.no_shuffle_deck) if(host_info.no_shuffle_deck)
opt |= DUEL_PSEUDO_SHUFFLE; opt |= DUEL_PSEUDO_SHUFFLE;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment