diff --git a/Platform/Apple/virtual/src/plasma/gamelib.plh b/Platform/Apple/virtual/src/plasma/gamelib.plh index 4ce0a443..1c237e71 100644 --- a/Platform/Apple/virtual/src/plasma/gamelib.plh +++ b/Platform/Apple/virtual/src/plasma/gamelib.plh @@ -30,6 +30,7 @@ import gamelib predef addPlayerToParty, removePlayerFromParty, partyHasPlayer, loadFrameImg, loadMainFrameImg predef scriptSwapTile, setIntimateMode, fontCmd, setIntimateMode predef callGlobalFunc, getCharResponse, memcpy, checkEncounter, finalWin, addUnique + predef benchPlayer, unbenchPlayer // This pointer is the root of all heap-tracked (and garbage collected) objects. // See playtype.plh for definitions of all the datastructures and how they interconnect. diff --git a/Platform/Apple/virtual/src/plasma/party.pla b/Platform/Apple/virtual/src/plasma/party.pla index 07f4bffb..d09c325d 100644 --- a/Platform/Apple/virtual/src/plasma/party.pla +++ b/Platform/Apple/virtual/src/plasma/party.pla @@ -374,11 +374,12 @@ def selectPlayer(players) player = players n_item = 0 while player - if player->b_playerFlags & PLAYER_FLAG_NPC; continue; fin - displayf1("\n%c)", 'A' + n_item) - rawDisplayStr("^T018") - displayStr(player=>s_name) - n_item++ + if player->b_playerFlags & PLAYER_FLAG_NPC + displayf1("\n%c)", 'A' + n_item) + rawDisplayStr("^T018") + displayStr(player=>s_name) + n_item++ + fin player = player=>p_nextObj loop @@ -388,14 +389,19 @@ def selectPlayer(players) fin // Then get a selection - rawDisplayStr("\n^T032Which character?") + rawDisplayStr("\nWhich character?") n_item = getUpperKey() - 'A' player = players - while n_item > 0 and player + while player + if player->b_playerFlags & PLAYER_FLAG_NPC + if n_item == 0 + break + fin + n_item-- + fin player = player=>p_nextObj - n_item-- loop - return player + return player end /////////////////////////////////////////////////////////////////////////////////////////////////// diff --git a/Platform/Apple/virtual/src/plasma/playtype.pla b/Platform/Apple/virtual/src/plasma/playtype.pla index 2fae1943..13b2324d 100644 --- a/Platform/Apple/virtual/src/plasma/playtype.pla +++ b/Platform/Apple/virtual/src/plasma/playtype.pla @@ -9,7 +9,7 @@ /////////////////////////////////////////////////////////////////////////////////////////////////// // Garbage collection pointer offsets within each type -byte typeTbl_Global[] = Global, p_players, p_enemyGroups, p_combatFirst, p_encounterZones, s_mapName, p_gameFlags, 0 +byte typeTbl_Global[] = Global, p_players, p_benched, p_enemyGroups, p_combatFirst, p_encounterZones, s_mapName, p_gameFlags, 0 byte typeTbl_Player[] = Player, p_nextObj, s_name, p_combatNext, p_skills, p_items, p_effects, 0 byte typeTbl_Modifier[] = Modifier, p_nextObj, s_name, 0 byte typeTbl_Effect[] = Effect, p_nextObj, s_name, 0