[Scummvm-git-logs] scummvm master -> 9ca315157972ec955796f685beedda2dcb6ceefd

mduggan mgithub at guarana.org
Mon Mar 23 13:35:32 UTC 2020


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
9ca3151579 ULTIMA8: More small const correctness changes


Commit: 9ca315157972ec955796f685beedda2dcb6ceefd
    https://github.com/scummvm/scummvm/commit/9ca315157972ec955796f685beedda2dcb6ceefd
Author: Matthew Duggan (mgithub at guarana.org)
Date: 2020-03-23T22:33:28+09:00

Commit Message:
ULTIMA8: More small const correctness changes

Changed paths:
    engines/ultima/ultima8/filesys/file_system.cpp
    engines/ultima/ultima8/filesys/file_system.h
    engines/ultima/ultima8/graphics/shape.cpp
    engines/ultima/ultima8/graphics/shape.h
    engines/ultima/ultima8/world/current_map.h


diff --git a/engines/ultima/ultima8/filesys/file_system.cpp b/engines/ultima/ultima8/filesys/file_system.cpp
index dacda8188c..e62bdfcbf1 100644
--- a/engines/ultima/ultima8/filesys/file_system.cpp
+++ b/engines/ultima/ultima8/filesys/file_system.cpp
@@ -265,7 +265,7 @@ IDataSource *FileSystem::checkBuiltinData(const Std::string &vfn, bool is_text)
 	return nullptr;
 }
 
-bool FileSystem::rewrite_virtual_path(string &vfn) {
+bool FileSystem::rewrite_virtual_path(string &vfn) const {
 	bool ret = false;
 	string::size_type pos = vfn.size();
 
diff --git a/engines/ultima/ultima8/filesys/file_system.h b/engines/ultima/ultima8/filesys/file_system.h
index 9b58a48321..385f1acc43 100644
--- a/engines/ultima/ultima8/filesys/file_system.h
+++ b/engines/ultima/ultima8/filesys/file_system.h
@@ -106,7 +106,7 @@ private:
 
 	// rewrite virtual path in-place (i.e., fvn is replaced)
 	// returns false if no rewriting was done
-	bool rewrite_virtual_path(Std::string &vfn);
+	bool rewrite_virtual_path(Std::string &vfn) const;
 
 	Std::map<Common::String, Std::string> _virtualPaths;
 
diff --git a/engines/ultima/ultima8/graphics/shape.cpp b/engines/ultima/ultima8/graphics/shape.cpp
index bb609c7e8c..feb95f3317 100644
--- a/engines/ultima/ultima8/graphics/shape.cpp
+++ b/engines/ultima/ultima8/graphics/shape.cpp
@@ -96,7 +96,7 @@ Shape::~Shape() {
 	delete[] const_cast<uint8 *>(_data);
 }
 
-void Shape::getShapeId(uint16 &id, uint32 &shape) {
+void Shape::getShapeId(uint16 &id, uint32 &shape) const {
 	id = _flexId;
 	shape = _shapeNum;
 }
diff --git a/engines/ultima/ultima8/graphics/shape.h b/engines/ultima/ultima8/graphics/shape.h
index 31f2495252..35ad75b602 100644
--- a/engines/ultima/ultima8/graphics/shape.h
+++ b/engines/ultima/ultima8/graphics/shape.h
@@ -62,7 +62,7 @@ public:
 
 	const ShapeFrame *getFrame(unsigned int frame) const;
 
-	void getShapeId(uint16 &flexId, uint32 &shapenum);
+	void getShapeId(uint16 &flexId, uint32 &shapenum) const;
 
 	// This will detect the format of a shape
 	static const ConvertShapeFormat *DetectShapeFormat(const uint8 *data, uint32 size);
diff --git a/engines/ultima/ultima8/world/current_map.h b/engines/ultima/ultima8/world/current_map.h
index c87dbe857f..d4ee592459 100644
--- a/engines/ultima/ultima8/world/current_map.h
+++ b/engines/ultima/ultima8/world/current_map.h
@@ -187,7 +187,7 @@ public:
 	// Not allowed to modify the list. Remember to use const_iterator
 	const Std::list<Item *> *getItemList(int32 gx, int32 gy) const;
 
-	bool isChunkFast(int32 cx, int32 cy) {
+	bool isChunkFast(int32 cx, int32 cy) const {
 		// CONSTANTS!
 		if (cx < 0 || cy < 0 || cx >= MAP_NUM_CHUNKS || cy >= MAP_NUM_CHUNKS)
 			return false;




More information about the Scummvm-git-logs mailing list