Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
walint
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
hub
walint
Commits
c82e15ae
Commit
c82e15ae
authored
3 years ago
by
Sven G. Brönstrup
Browse files
Options
Downloads
Patches
Plain Diff
Fixed types of extended scripts properties
parent
f3d0f937
Branches
extended-scripts
Branches containing commit
No related tags found
1 merge request
!1
Extended scripts support
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lib/Properties.hs
+8
-3
8 additions, 3 deletions
lib/Properties.hs
with
8 additions
and
3 deletions
lib/Properties.hs
+
8
−
3
View file @
c82e15ae
...
@@ -261,10 +261,14 @@ checkObjectProperty p@(Property name _) = do
...
@@ -261,10 +261,14 @@ checkObjectProperty p@(Property name _) = do
$
complain
"property
\"
soundRadius
\"
can only be set on objects with
\
$
complain
"property
\"
soundRadius
\"
can only be set on objects with
\
\
either property
\"
bell
\"
or
\"
door
\"
also set."
\
either property
\"
bell
\"
or
\"
door
\"
also set."
_
|
name
`
elem
`
[
"default"
,
"persist"
,
"openLayer"
,
"closeLayer"
]
->
do
_
|
name
`
elem
`
[
"default"
,
"persist"
]
->
do
isBool
p
isBool
p
suggestPropertyName'
"door"
suggestPropertyName'
"door"
-- extended API for doors and bells
-- extended API for doors and bells
|
name
`
elem
`
[
"openLayer"
,
"closeLayer"
]
->
do
isString
p
suggestPropertyName'
"door"
-- extended API for doors and bells
|
name
`
elem
`
[
"door"
,
"bell"
]
->
do
|
name
`
elem
`
[
"door"
,
"bell"
]
->
do
isBool
p
isBool
p
unless
(
objectType
obj
==
"variable"
)
$
unless
(
objectType
obj
==
"variable"
)
$
...
@@ -441,9 +445,10 @@ checkTileLayerProperty p@(Property name _value) = case name of
...
@@ -441,9 +445,10 @@ checkTileLayerProperty p@(Property name _value) = case name of
"name"
->
isUnsupported
"name"
->
isUnsupported
_
|
name
`
elem
`
[
"doorVariable"
,
"bindVariable"
,
"bellVariable"
]
_
|
name
`
elem
`
[
"doorVariable"
,
"bindVariable"
,
"bellVariable"
]
->
do
{
isString
p
;
requireProperty
"zone"
}
->
do
{
isString
p
;
requireProperty
"zone"
}
|
name
`
elem
`
[
"autoOpen"
,
"autoClose"
,
"code"
|
name
`
elem
`
[
"code"
,
"openTriggerMessage"
,
"closeTriggerMessage"
]
,
"openTriggerMessage"
,
"closeTriggerMessage"
]
->
do
{
isString
p
;
requireProperty
"doorVariable"
}
->
do
{
isString
p
;
requireProperty
"doorVariable"
}
|
name
`
elem
`
[
"autoOpen"
,
"autoClose"
]
->
do
{
isBool
p
;
requireProperty
"doorVariable"
}
|
name
`
elem
`
[
"bellButtonText"
,
"bellPopup"
]
|
name
`
elem
`
[
"bellButtonText"
,
"bellPopup"
]
->
do
{
isString
p
;
requireProperty
"bellVariable"
}
->
do
{
isString
p
;
requireProperty
"bellVariable"
}
|
name
`
elem
`
[
"enterValue"
,
"leaveValue"
]
|
name
`
elem
`
[
"enterValue"
,
"leaveValue"
]
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment