diff --git a/network/network_cmd_ingame.cc b/network/network_cmd_ingame.cc index ebd6eb92054..64609bf210d 100644 --- a/network/network_cmd_ingame.cc +++ b/network/network_cmd_ingame.cc @@ -946,7 +946,7 @@ nwc_tool_t::nwc_tool_t(spieler_t *sp, werkzeug_t *wkz, koord3d pos_, uint32 sync // write custom data of wkz to our internal buffer custom_data = new memory_rw_t(custom_data_buf, lengthof(custom_data_buf), true); if (sp) { - wkz->rdwr_custom_data(sp->get_player_nr(), custom_data); + wkz->rdwr_custom_data(custom_data); } } @@ -1225,7 +1225,7 @@ void nwc_tool_t::do_command(karte_t *welt) if( wkz ) { // read custom data - wkz->rdwr_custom_data(player_nr, custom_data); + wkz->rdwr_custom_data(custom_data); // set flags correctly if (local) { wkz->flags = flags | werkzeug_t::WFL_LOCAL; diff --git a/simmenu.cc b/simmenu.cc index 7b9257cd707..cfdc2238e47 100644 --- a/simmenu.cc +++ b/simmenu.cc @@ -847,7 +847,7 @@ bool two_click_werkzeug_t::init(spieler_t *) } -void two_click_werkzeug_t::rdwr_custom_data(uint8, memory_rw_t *packet) +void two_click_werkzeug_t::rdwr_custom_data(memory_rw_t *packet) { packet->rdwr_bool(first_click_var); sint16 posx = start.x; packet->rdwr_short(posx); start.x = posx; diff --git a/simmenu.h b/simmenu.h index 5ae0064e540..83552551768 100644 --- a/simmenu.h +++ b/simmenu.h @@ -244,7 +244,7 @@ class werkzeug_t { void set_default_param(const char* str) { default_param = str; } // transfer additional information in networkgames - virtual void rdwr_custom_data(uint8 /* player_nr */, memory_rw_t*) { } + virtual void rdwr_custom_data(memory_rw_t*) { } // this will draw the tool with some indication, if active virtual bool is_selected() const; @@ -331,7 +331,7 @@ class two_click_werkzeug_t : public werkzeug_t { MEMZERO(start_marker); } - void rdwr_custom_data(uint8 player_nr, memory_rw_t*) OVERRIDE; + void rdwr_custom_data(memory_rw_t*) OVERRIDE; bool init(spieler_t*) OVERRIDE; bool exit(spieler_t* const sp) OVERRIDE { return init(sp); } diff --git a/simwerkz.cc b/simwerkz.cc index ceda4c253ab..47c7580d892 100644 --- a/simwerkz.cc +++ b/simwerkz.cc @@ -2356,9 +2356,9 @@ const char *wkz_brueckenbau_t::do_work( spieler_t *sp, const koord3d &start, con } } -void wkz_brueckenbau_t::rdwr_custom_data(uint8 player_nr, memory_rw_t *packet) +void wkz_brueckenbau_t::rdwr_custom_data(memory_rw_t *packet) { - two_click_werkzeug_t::rdwr_custom_data(player_nr, packet); + two_click_werkzeug_t::rdwr_custom_data(packet); uint8 i = ribi; packet->rdwr_byte(i); ribi = (ribi_t::ribi)i; diff --git a/simwerkz.h b/simwerkz.h index 567f3c2335e..416178e6414 100644 --- a/simwerkz.h +++ b/simwerkz.h @@ -298,7 +298,7 @@ class wkz_brueckenbau_t : public two_click_werkzeug_t { bool is_init_network_save() const OVERRIDE { return true; } waytype_t get_waytype() const OVERRIDE; bool remove_preview_necessary() const OVERRIDE { return !is_first_click(); } - void rdwr_custom_data(uint8 player_nr, memory_rw_t*) OVERRIDE; + void rdwr_custom_data(memory_rw_t*) OVERRIDE; }; class wkz_tunnelbau_t : public two_click_werkzeug_t {