summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornsensfel <SpamShield0@noot-noot.org>2018-10-11 17:49:47 +0200
committernsensfel <SpamShield0@noot-noot.org>2018-10-11 17:49:47 +0200
commitaea6e1872eeccffdef926b6561767ff59aecf87e (patch)
tree78b8848ccfa8d6002075bfe738ac0d66682e8add /src/shared
parent4182b46e67185e1f024a24e7cba0d82e24f29baa (diff)
(Broken) 'spe' to add new map to player.
Diffstat (limited to 'src/shared')
-rw-r--r--src/shared/struct/shr_db_user.erl4
-rw-r--r--src/shared/struct/shr_tile.erl.m46
2 files changed, 8 insertions, 2 deletions
diff --git a/src/shared/struct/shr_db_user.erl b/src/shared/struct/shr_db_user.erl
index 6087833..8368024 100644
--- a/src/shared/struct/shr_db_user.erl
+++ b/src/shared/struct/shr_db_user.erl
@@ -31,4 +31,6 @@ can_access (janitor, janitor) -> true;
can_access (List, {user, User}) ->
lists:member({user, User}, List);
can_access (List, janitor) ->
- lists:member(janitor, List).
+ lists:member(janitor, List);
+can_access (List, User) ->
+ can_access(List, {user, User}).
diff --git a/src/shared/struct/shr_tile.erl.m4 b/src/shared/struct/shr_tile.erl.m4
index 750e59a..906dc84 100644
--- a/src/shared/struct/shr_tile.erl.m4
+++ b/src/shared/struct/shr_tile.erl.m4
@@ -42,7 +42,8 @@
(
[
instance_to_int_list/1,
- instance_from_ints/1
+ instance_from_ints/1,
+ default_tile_instance/0
]
).
@@ -123,3 +124,6 @@ instance_from_ints (L) ->
-spec instance_to_int_list (instance()) -> list(non_neg_integer()).
instance_to_int_list (I) -> I.
+
+-spec default_tile_instance () -> instance().
+default_tile_instance () -> [1, 0].