Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
RLG Maker
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Romain DELEAU
RLG Maker
Commits
26778f08
Commit
26778f08
authored
Apr 19, 2024
by
Romain DELEAU
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove symbol on taskPaste if already used in the role
parent
a21bd548
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
27 additions
and
6 deletions
+27
-6
annexe-task.component.ts
src/app/pieces/tasks/annexe-task/annexe-task.component.ts
+2
-1
final-task.component.ts
src/app/pieces/tasks/final-task/final-task.component.ts
+6
-1
optionnal-task.component.ts
...p/pieces/tasks/optionnal-task/optionnal-task.component.ts
+6
-1
random-event.component.ts
src/app/pieces/tasks/random-event/random-event.component.ts
+6
-1
repeat-task.component.ts
src/app/pieces/tasks/repeat-task/repeat-task.component.ts
+1
-1
task.component.ts
src/app/pieces/tasks/task/task.component.ts
+6
-1
No files found.
src/app/pieces/tasks/annexe-task/annexe-task.component.ts
View file @
26778f08
...
@@ -162,7 +162,8 @@ export class AnnexeTaskComponent implements OnInit {
...
@@ -162,7 +162,8 @@ export class AnnexeTaskComponent implements OnInit {
}
}
onClickPaste
()
{
onClickPaste
()
{
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);;
let
newTask
:
Task
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
newTask
;
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
...
...
src/app/pieces/tasks/final-task/final-task.component.ts
View file @
26778f08
...
@@ -17,6 +17,7 @@ import { MinimapService } from 'src/app/services/minimap/minimap.service';
...
@@ -17,6 +17,7 @@ import { MinimapService } from 'src/app/services/minimap/minimap.service';
import
{
TranslateService
}
from
'@ngx-translate/core'
;
import
{
TranslateService
}
from
'@ngx-translate/core'
;
import
{
UnityService
}
from
'src/app/services/unity/unity.service'
;
import
{
UnityService
}
from
'src/app/services/unity/unity.service'
;
import
{
CopyTaskService
}
from
'src/app/services/copyTask/copy-task.service'
;
import
{
CopyTaskService
}
from
'src/app/services/copyTask/copy-task.service'
;
import
{
Symbol
}
from
'src/app/class/symbol/symbol'
;
@
Component
({
@
Component
({
selector
:
'app-final-task'
,
selector
:
'app-final-task'
,
...
@@ -165,7 +166,11 @@ export class FinalTaskComponent implements OnInit {
...
@@ -165,7 +166,11 @@ export class FinalTaskComponent implements OnInit {
}
}
onClickPaste
()
{
onClickPaste
()
{
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);;
let
newTask
:
Task
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);
if
(
this
.
canUseSymbol
(
newTask
.
symbol
.
symbol
,
newTask
.
symbol
.
color
)
==
'disable'
)
{
newTask
.
symbol
=
new
Symbol
();
}
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
newTask
;
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
...
...
src/app/pieces/tasks/optionnal-task/optionnal-task.component.ts
View file @
26778f08
...
@@ -17,6 +17,7 @@ import { MinimapService } from 'src/app/services/minimap/minimap.service';
...
@@ -17,6 +17,7 @@ import { MinimapService } from 'src/app/services/minimap/minimap.service';
import
{
TranslateService
}
from
'@ngx-translate/core'
;
import
{
TranslateService
}
from
'@ngx-translate/core'
;
import
{
UnityService
}
from
'src/app/services/unity/unity.service'
;
import
{
UnityService
}
from
'src/app/services/unity/unity.service'
;
import
{
CopyTaskService
}
from
'src/app/services/copyTask/copy-task.service'
;
import
{
CopyTaskService
}
from
'src/app/services/copyTask/copy-task.service'
;
import
{
Symbol
}
from
'src/app/class/symbol/symbol'
;
@
Component
({
@
Component
({
selector
:
'app-optionnal-task'
,
selector
:
'app-optionnal-task'
,
...
@@ -170,7 +171,11 @@ export class OptionnalTaskComponent implements OnInit {
...
@@ -170,7 +171,11 @@ export class OptionnalTaskComponent implements OnInit {
}
}
onClickPaste
()
{
onClickPaste
()
{
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);;
let
newTask
:
Task
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);
if
(
this
.
canUseSymbol
(
newTask
.
symbol
.
symbol
,
newTask
.
symbol
.
color
)
==
'disable'
)
{
newTask
.
symbol
=
new
Symbol
();
}
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
newTask
;
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
...
...
src/app/pieces/tasks/random-event/random-event.component.ts
View file @
26778f08
...
@@ -17,6 +17,7 @@ import { MinimapService } from 'src/app/services/minimap/minimap.service';
...
@@ -17,6 +17,7 @@ import { MinimapService } from 'src/app/services/minimap/minimap.service';
import
{
TranslateService
}
from
'@ngx-translate/core'
;
import
{
TranslateService
}
from
'@ngx-translate/core'
;
import
{
UnityService
}
from
'src/app/services/unity/unity.service'
;
import
{
UnityService
}
from
'src/app/services/unity/unity.service'
;
import
{
CopyTaskService
}
from
'src/app/services/copyTask/copy-task.service'
;
import
{
CopyTaskService
}
from
'src/app/services/copyTask/copy-task.service'
;
import
{
Symbol
}
from
'src/app/class/symbol/symbol'
;
@
Component
({
@
Component
({
selector
:
'app-random-event'
,
selector
:
'app-random-event'
,
...
@@ -155,7 +156,11 @@ export class RandomEventComponent implements OnInit {
...
@@ -155,7 +156,11 @@ export class RandomEventComponent implements OnInit {
}
}
onClickPaste
()
{
onClickPaste
()
{
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);;
let
newTask
:
Task
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);
if
(
this
.
canUseSymbol
(
newTask
.
symbol
.
symbol
,
newTask
.
symbol
.
color
)
==
'disable'
)
{
newTask
.
symbol
=
new
Symbol
();
}
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
newTask
;
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
...
...
src/app/pieces/tasks/repeat-task/repeat-task.component.ts
View file @
26778f08
...
@@ -97,7 +97,7 @@ export class RepeatTaskComponent implements OnInit {
...
@@ -97,7 +97,7 @@ export class RepeatTaskComponent implements OnInit {
}
}
onClickPaste
()
{
onClickPaste
()
{
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);
;
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);
}
}
moveTask
(
direction
:
string
):
void
{
moveTask
(
direction
:
string
):
void
{
...
...
src/app/pieces/tasks/task/task.component.ts
View file @
26778f08
...
@@ -18,6 +18,7 @@ import { TranslateService } from '@ngx-translate/core';
...
@@ -18,6 +18,7 @@ import { TranslateService } from '@ngx-translate/core';
import
{
TutorialService
}
from
'src/app/services/tutorial/tutorial.service'
;
import
{
TutorialService
}
from
'src/app/services/tutorial/tutorial.service'
;
import
{
UnityService
}
from
'src/app/services/unity/unity.service'
;
import
{
UnityService
}
from
'src/app/services/unity/unity.service'
;
import
{
CopyTaskService
}
from
'src/app/services/copyTask/copy-task.service'
;
import
{
CopyTaskService
}
from
'src/app/services/copyTask/copy-task.service'
;
import
{
Symbol
}
from
'src/app/class/symbol/symbol'
;
@
Component
({
@
Component
({
selector
:
'app-task'
,
selector
:
'app-task'
,
...
@@ -166,7 +167,11 @@ export class TaskComponent implements OnInit {
...
@@ -166,7 +167,11 @@ export class TaskComponent implements OnInit {
}
}
onClickPaste
()
{
onClickPaste
()
{
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);;
let
newTask
:
Task
=
this
.
copyTaskService
.
onClickPaste
(
this
.
scenario
);
if
(
this
.
canUseSymbol
(
newTask
.
symbol
.
symbol
,
newTask
.
symbol
.
color
)
==
'disable'
)
{
newTask
.
symbol
=
new
Symbol
();
}
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
=
newTask
;
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
if
(
this
.
role
.
isAlreadyUsedIdentifier
((
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
))
{
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
this
.
_snackBar
.
open
(
this
.
translate
.
instant
(
'snackbar_identifier'
),
''
,
{
duration
:
5000
,
panelClass
:
'snackbar-fail'
});
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
(
this
.
role
.
tasks
[
this
.
i
][
this
.
j
]
as
Task
).
identifier
=
''
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment