From 83cd7ce064b8a46a106dc855d748b1bd7e45af01 Mon Sep 17 00:00:00 2001 From: nsensfel Date: Fri, 4 Jan 2019 17:25:39 +0100 Subject: Removes 'id' field from ataxia entry values. While sometimes usefull as a way to retrieve the object's ID, they were both redundant (you can't get the object without its ID anyway) and bothersome to maintain (insert + update, which would have required setting up a bounty for any insert). --- src/bounty/bnt_join_battle.erl | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/bounty/bnt_join_battle.erl') diff --git a/src/bounty/bnt_join_battle.erl b/src/bounty/bnt_join_battle.erl index f97b20b..5daa548 100644 --- a/src/bounty/bnt_join_battle.erl +++ b/src/bounty/bnt_join_battle.erl @@ -413,13 +413,12 @@ generate_battle (PlayerID, MapID) -> map_map:id(), list(non_neg_integer()) ) - -> btl_pending_battle:type(). + -> {btl_pending_battle:id(), btl_pending_battle:type()}. generate (PlayerID, MapID, SelectedRosterCharacterIXs) -> Battle = generate_battle(PlayerID, MapID), PendingBattle = btl_pending_battle:new ( - <<"">>, % TODO: More options than 1 vs N. (length(SelectedRosterCharacterIXs) * 2), Battle @@ -433,7 +432,7 @@ generate (PlayerID, MapID, SelectedRosterCharacterIXs) -> list(non_neg_integer()), btl_pending_battle:type() ) - -> btl_pending_battle:type(). + -> {btl_pending_battle:id(), btl_pending_battle:type()}. attempt (PlayerID, SelectedRosterCharacterIXs, PendingBattle) -> Battle = btl_pending_battle:get_battle(PendingBattle), RemainingSlots = @@ -476,7 +475,7 @@ attempt (PlayerID, SelectedRosterCharacterIXs, PendingBattle) -> {S1PendingBattle, Update}, - S1PendingBattle. + {ataxia_id:null(), S1PendingBattle}. % TODO: % if RemainingSlots = 0 -> del this, new Battle. -- cgit v1.2.3-70-g09d2