From b9bfa3a85704c705e7b628a28d9e34a32e210ceb Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Tue, 18 Feb 2014 02:34:26 +0100 Subject: TONY: Make GPL headers consistent in themselves. --- engines/tony/mpal/mpal.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'engines/tony/mpal/mpal.cpp') diff --git a/engines/tony/mpal/mpal.cpp b/engines/tony/mpal/mpal.cpp index 19e3d43df4..797c7dbae0 100644 --- a/engines/tony/mpal/mpal.cpp +++ b/engines/tony/mpal/mpal.cpp @@ -8,17 +8,16 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * */ /* * This code is based on original Tony Tough source code -- cgit v1.2.3 From d35f470bf6290eb9ab5a86321b223ae3f1cb48fa Mon Sep 17 00:00:00 2001 From: Strangerke Date: Fri, 28 Feb 2014 22:20:38 +0100 Subject: TONY: Reduce the scope of some variables, change the return type of findPath() --- engines/tony/mpal/mpal.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'engines/tony/mpal/mpal.cpp') diff --git a/engines/tony/mpal/mpal.cpp b/engines/tony/mpal/mpal.cpp index 797c7dbae0..3084fd89af 100644 --- a/engines/tony/mpal/mpal.cpp +++ b/engines/tony/mpal/mpal.cpp @@ -1524,7 +1524,6 @@ void mpalFree() { uint32 mpalQueryDWORD(uint16 wQueryType, ...) { Common::String buf; uint32 dwRet = 0; - char *n; va_list v; va_start(v, wQueryType); @@ -1625,7 +1624,7 @@ uint32 mpalQueryDWORD(uint16 wQueryType, ...) { */ lockVar(); int x = GETARG(uint32); - n = GETARG(char *); + char *n = GETARG(char *); buf = Common::String::format("Status.%u", x); if (varGetValue(buf.c_str()) <= 0) n[0]='\0'; -- cgit v1.2.3 From f358ec74f7ac4575e5450fd468a46aba2190da91 Mon Sep 17 00:00:00 2001 From: Strangerke Date: Fri, 28 Feb 2014 22:47:36 +0100 Subject: TONY: Reduce the scope of some more variables --- engines/tony/mpal/mpal.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'engines/tony/mpal/mpal.cpp') diff --git a/engines/tony/mpal/mpal.cpp b/engines/tony/mpal/mpal.cpp index 3084fd89af..305f89765b 100644 --- a/engines/tony/mpal/mpal.cpp +++ b/engines/tony/mpal/mpal.cpp @@ -1718,7 +1718,6 @@ uint32 mpalQueryDWORD(uint16 wQueryType, ...) { * method that returns a pointer or handle. */ MpalHandle mpalQueryHANDLE(uint16 wQueryType, ...) { - char *n; Common::String buf; va_list v; va_start(v, wQueryType); @@ -1796,12 +1795,9 @@ MpalHandle mpalQueryHANDLE(uint16 wQueryType, ...) { error("mpalQuery(MPQ_ITEM_IS_ACTIVE, uint32 nItem) used incorrect variant"); } else if (wQueryType == MPQ_ITEM_NAME) { - /* - * uint32 mpalQuery(MPQ_ITEM_NAME, uint32 nItem, char *lpszName); - */ lockVar(); int x = GETARG(uint32); - n = GETARG(char *); + char *n = GETARG(char *); buf = Common::String::format("Status.%u", x); if (varGetValue(buf.c_str()) <= 0) n[0] = '\0'; -- cgit v1.2.3 From 81d733aec0c4422fa8c0b34b0c7f4d5b74c991c0 Mon Sep 17 00:00:00 2001 From: Strangerke Date: Fri, 28 Feb 2014 22:49:05 +0100 Subject: TONY: Fix some British comments --- engines/tony/mpal/mpal.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'engines/tony/mpal/mpal.cpp') diff --git a/engines/tony/mpal/mpal.cpp b/engines/tony/mpal/mpal.cpp index 305f89765b..c813b354b0 100644 --- a/engines/tony/mpal/mpal.cpp +++ b/engines/tony/mpal/mpal.cpp @@ -1518,7 +1518,7 @@ void mpalFree() { * * @param wQueryType Type of query. The list is in the QueryTypes enum. * @returns 4 bytes depending on the type of query - * @remarks This is the specialised version of the original single mpalQuery + * @remarks This is the specialized version of the original single mpalQuery * method that returns numeric results. */ uint32 mpalQueryDWORD(uint16 wQueryType, ...) { @@ -1714,7 +1714,7 @@ uint32 mpalQueryDWORD(uint16 wQueryType, ...) { * * @param wQueryType Type of query. The list is in the QueryTypes enum. * @returns 4 bytes depending on the type of query - * @remarks This is the specialised version of the original single mpalQuery + * @remarks This is the specialized version of the original single mpalQuery * method that returns a pointer or handle. */ MpalHandle mpalQueryHANDLE(uint16 wQueryType, ...) { @@ -1867,7 +1867,7 @@ MpalHandle mpalQueryHANDLE(uint16 wQueryType, ...) { * * @param wQueryType Type of query. The list is in the QueryTypes enum. * @returns 4 bytes depending on the type of query - * @remarks This is the specialised version of the original single mpalQuery + * @remarks This is the specialized version of the original single mpalQuery * method that needs to run within a co-routine context. */ void mpalQueryCORO(CORO_PARAM, uint16 wQueryType, uint32 *dwRet) { -- cgit v1.2.3