Commit b2f206de authored by nanahira's avatar nanahira

Merge branch 'dev-salixthing' into dev-salixthing-server

parents 9ef1f807 1e1fb28e
...@@ -167,8 +167,6 @@ bool ReplayMode::StartDuel() { ...@@ -167,8 +167,6 @@ bool ReplayMode::StartDuel() {
cur_replay.ReadName(mainGame->dInfo.clientname); cur_replay.ReadName(mainGame->dInfo.clientname);
} }
pduel = create_duel(rnd()); pduel = create_duel(rnd());
preload_script(pduel, "./script/special.lua", 0);
preload_script(pduel, "./script/init.lua", 0);
int start_lp = cur_replay.ReadInt32(); int start_lp = cur_replay.ReadInt32();
int start_hand = cur_replay.ReadInt32(); int start_hand = cur_replay.ReadInt32();
int draw_count = cur_replay.ReadInt32(); int draw_count = cur_replay.ReadInt32();
...@@ -177,6 +175,8 @@ bool ReplayMode::StartDuel() { ...@@ -177,6 +175,8 @@ bool ReplayMode::StartDuel() {
mainGame->dInfo.duel_rule = duel_rule; mainGame->dInfo.duel_rule = duel_rule;
set_player_info(pduel, 0, start_lp, start_hand, draw_count); set_player_info(pduel, 0, start_lp, start_hand, draw_count);
set_player_info(pduel, 1, start_lp, start_hand, draw_count); set_player_info(pduel, 1, start_lp, start_hand, draw_count);
preload_script(pduel, "./script/special.lua", 0);
preload_script(pduel, "./script/init.lua", 0);
mainGame->dInfo.lp[0] = start_lp; mainGame->dInfo.lp[0] = start_lp;
mainGame->dInfo.lp[1] = start_lp; mainGame->dInfo.lp[1] = start_lp;
mainGame->dInfo.start_lp = start_lp; mainGame->dInfo.start_lp = start_lp;
......
...@@ -41,10 +41,10 @@ int SingleMode::SinglePlayThread() { ...@@ -41,10 +41,10 @@ int SingleMode::SinglePlayThread() {
set_card_reader(DataManager::CardReader); set_card_reader(DataManager::CardReader);
set_message_handler(SingleMode::MessageHandler); set_message_handler(SingleMode::MessageHandler);
pduel = create_duel(rnd.rand()); pduel = create_duel(rnd.rand());
preload_script(pduel, "./script/special.lua", 0);
preload_script(pduel, "./script/init.lua", 0);
set_player_info(pduel, 0, start_lp, start_hand, draw_count); set_player_info(pduel, 0, start_lp, start_hand, draw_count);
set_player_info(pduel, 1, start_lp, start_hand, draw_count); set_player_info(pduel, 1, start_lp, start_hand, draw_count);
preload_script(pduel, "./script/special.lua", 0);
preload_script(pduel, "./script/init.lua", 0);
mainGame->dInfo.lp[0] = start_lp; mainGame->dInfo.lp[0] = start_lp;
mainGame->dInfo.lp[1] = start_lp; mainGame->dInfo.lp[1] = start_lp;
mainGame->dInfo.start_lp = start_lp; mainGame->dInfo.start_lp = start_lp;
......
...@@ -548,10 +548,10 @@ void TagDuel::TPResult(DuelPlayer* dp, unsigned char tp) { ...@@ -548,10 +548,10 @@ void TagDuel::TPResult(DuelPlayer* dp, unsigned char tp) {
set_card_reader(DataManager::CardReader); set_card_reader(DataManager::CardReader);
set_message_handler(TagDuel::MessageHandler); set_message_handler(TagDuel::MessageHandler);
pduel = create_duel(duel_seed); pduel = create_duel(duel_seed);
preload_script(pduel, "./script/special.lua", 0);
preload_script(pduel, "./script/init.lua", 0);
set_player_info(pduel, 0, host_info.start_lp, host_info.start_hand, host_info.draw_count); 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); set_player_info(pduel, 1, host_info.start_lp, host_info.start_hand, host_info.draw_count);
preload_script(pduel, "./script/special.lua", 0);
preload_script(pduel, "./script/init.lua", 0);
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