Skip to content

Commit 631f31a

Browse files
committed
Merge branch 'release/1.3.8'
2 parents 513c519 + d61e525 commit 631f31a

26 files changed

+205
-72
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ If applicable, add screenshots to help explain your problem.
2424

2525
**Desktop (please complete the following information):**
2626
- OS: [e.g. mac/linux/windows]
27-
- Version [e.g. 1.3.7]
27+
- Version [e.g. 1.3.8]
2828

2929
**Additional context**
3030
Add any other context about the problem here.

CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cmake_minimum_required(VERSION 3.10.0)
22
set(CMAKE_OSX_DEPLOYMENT_TARGET "10.9" CACHE STRING "Minimum OS X deployment version")
3-
project(Griddly VERSION 1.3.7)
3+
project(Griddly VERSION 1.3.8)
44

55
set(BINARY ${CMAKE_PROJECT_NAME})
66

bindings/python.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ namespace griddly {
1212

1313
PYBIND11_MODULE(python_griddly, m) {
1414
m.doc() = "Griddly python bindings";
15-
m.attr("version") = "1.3.7";
15+
m.attr("version") = "1.3.8";
1616

1717
#ifndef NDEBUG
1818
spdlog::set_level(spdlog::level::debug);
@@ -23,7 +23,7 @@ PYBIND11_MODULE(python_griddly, m) {
2323
spdlog::debug("Python Griddly module loaded!");
2424

2525
py::class_<Py_GriddlyLoaderWrapper, std::shared_ptr<Py_GriddlyLoaderWrapper>> gdy_reader(m, "GDYReader");
26-
gdy_reader.def(py::init<std::string, std::string>());
26+
gdy_reader.def(py::init<std::string, std::string, std::string>());
2727
gdy_reader.def("load", &Py_GriddlyLoaderWrapper::loadGDYFile);
2828
gdy_reader.def("load_string", &Py_GriddlyLoaderWrapper::loadGDYString);
2929

bindings/wrapper/GriddlyLoaderWrapper.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ namespace griddly {
1212

1313
class Py_GriddlyLoaderWrapper {
1414
public:
15-
Py_GriddlyLoaderWrapper(std::string imagePath, std::string shaderPath)
16-
: resourceConfig_({imagePath, shaderPath}) {
15+
Py_GriddlyLoaderWrapper(std::string gdyPath, std::string imagePath, std::string shaderPath)
16+
: resourceConfig_({gdyPath, imagePath, shaderPath}) {
1717
}
1818

1919
std::shared_ptr<Py_GDYWrapper> loadGDYFile(std::string filename) {

docs/conf.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
author = 'Chris Bamford'
2323

2424
# The full version, including alpha/beta/rc tags
25-
release = '1.3.7'
25+
release = '1.3.8'
2626

2727

2828
# -- General configuration ---------------------------------------------------

js/jiddly-app/package-lock.json

+69-32
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

js/jiddly-app/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "jiddly-app",
3-
"version": "1.3.7",
3+
"version": "1.3.8",
44
"private": true,
55
"dependencies": {
66
"@fortawesome/fontawesome-svg-core": "^6.1.1",

python/griddly/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def __init__(self, gdy_path=None, image_path=None, shader_path=None):
3434
if gdy_path is None
3535
else gdy_path
3636
)
37-
self._gdy_reader = gd.GDYReader(self._image_path, self._shader_path)
37+
self._gdy_reader = gd.GDYReader(self._gdy_path, self._image_path, self._shader_path)
3838

3939
def get_full_path(self, gdy_path):
4040
# Assume the file is relative first and if not, try to find it in the pre-defined games

python/setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ def griddly_package_data(config='Debug'):
7171

7272
setup(
7373
name='griddly',
74-
version="1.3.7",
74+
version="1.3.8",
7575
author_email="chrisbam4d@gmail.com",
7676
description="Griddly Python Libraries",
7777
long_description=long_description,

python/tests/history_test.py

+25-3
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,23 @@ def build_test_env(test_name, yaml_file, enable_history=True):
2525
return env
2626

2727

28+
def eq_dict(dict1, dict2):
29+
30+
for key in dict1:
31+
if key in dict2:
32+
if dict1[key] != dict2[key]:
33+
return False
34+
else:
35+
assert False
36+
return True
37+
38+
def in_dict(list_of_dicts, dict):
39+
for dict1 in list_of_dicts:
40+
if eq_dict(dict1, dict):
41+
return True
42+
return False
43+
44+
2845
def test_history_SinglePlayer_HasHistory(test_name):
2946
"""
3047
Assuming there is a single avatar
@@ -122,7 +139,9 @@ def test_history_SinglePlayer_MultipleAction(test_name):
122139
},
123140
]
124141

125-
assert info["History"] == expected_history
142+
assert in_dict(info["History"], expected_history[0])
143+
assert in_dict(info["History"], expected_history[1])
144+
126145

127146

128147
def test_history_MultiplePlayer_History(test_name):
@@ -170,7 +189,8 @@ def test_history_MultiplePlayer_History(test_name):
170189
},
171190
]
172191

173-
assert info["History"] == expected_history
192+
assert in_dict(info["History"], expected_history[0])
193+
assert in_dict(info["History"], expected_history[1])
174194

175195

176196
def test_history_MultiplePlayer_MultipleAction_History(test_name):
@@ -238,4 +258,6 @@ def test_history_MultiplePlayer_MultipleAction_History(test_name):
238258
},
239259
]
240260

241-
assert info["History"] == expected_history
261+
assert in_dict(info["History"], expected_history[0])
262+
assert in_dict(info["History"], expected_history[1])
263+
assert in_dict(info["History"], expected_history[2])

0 commit comments

Comments
 (0)