Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
FirefighterStarter
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
OUALAN Yanis
FirefighterStarter
Commits
8b8dd77b
Commit
8b8dd77b
authored
5 months ago
by
Yanis O
Browse files
Options
Downloads
Patches
Plain Diff
[Fix] getImage utilise une version statique de l'image plutôt que d'en créer une nouvelle
parent
0e6bc285
Branches
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#40646
failed
5 months ago
Stage: build
Stage: test
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/main/java/model/firefighterscenario/Cloud.java
+10
-3
10 additions, 3 deletions
src/main/java/model/firefighterscenario/Cloud.java
src/main/resources/view/nuage.png
+0
-0
0 additions, 0 deletions
src/main/resources/view/nuage.png
with
10 additions
and
3 deletions
src/main/java/model/firefighterscenario/Cloud.java
+
10
−
3
View file @
8b8dd77b
...
...
@@ -17,8 +17,15 @@ public class Cloud implements Entity{
private
final
Color
viewColor
=
Color
.
GRAY
;
private
final
int
priority
=
2
;
private
static
javafx
.
scene
.
image
.
Image
cloudImage
;
static
{
try
{
cloudImage
=
new
javafx
.
scene
.
image
.
Image
(
Cloud
.
class
.
getResource
(
"/view/nuage.png"
).
toExternalForm
());
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
public
Cloud
(
Position
position
,
Board
<
Square
>
b
){
this
.
age
=
0
;
this
.
position
=
position
;
...
...
@@ -110,7 +117,7 @@ public class Cloud implements Entity{
public
javafx
.
scene
.
image
.
Image
getImage
()
{
return
new
javafx
.
scene
.
image
.
Image
(
getClass
().
getResource
(
"/icons/img.png"
).
toExternalForm
())
;
return
cloudImage
;
}
...
...
This diff is collapsed.
Click to expand it.
src/main/resources/view/nuage.png
0 → 100644
+
0
−
0
View file @
8b8dd77b
64.3 KiB
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