Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
MoteurDeJeu
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
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Villard PierreFrederic
MoteurDeJeu
Commits
e21096a7
Commit
e21096a7
authored
3 years ago
by
Villard PierreFrederic
Browse files
Options
Downloads
Patches
Plain Diff
Remove a bug stopping the background to move without the subjective view
parent
ae503abb
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/afficheur/DecorVariable.java
+6
-0
6 additions, 0 deletions
src/afficheur/DecorVariable.java
test/testMario.java
+1
-1
1 addition, 1 deletion
test/testMario.java
with
7 additions
and
1 deletion
src/afficheur/DecorVariable.java
+
6
−
0
View file @
e21096a7
...
...
@@ -49,6 +49,8 @@ public class DecorVariable {
//declae en x seulement
public
void
affiche
(
int
x
,
Graphics
g
)
{
if
(
Repere
.
isSubjective
)
{
//on se ramene au repere du plan
x
=(
x
%
wx
);
...
...
@@ -57,6 +59,10 @@ public class DecorVariable {
//on affiche sur l'ecran wx-x ==> wx image source de 0 � x
g
.
drawImage
(
im
,
wx
-
x
,
0
,
wx
,
wy
,
0
,
0
,
x
,
wy
,
null
);
}
else
{
g
.
drawImage
(
im
,
0
,
0
,
wx
,
wy
,
0
,
0
,
wx
,
wy
,
null
);
}
}
...
...
This diff is collapsed.
Click to expand it.
test/testMario.java
+
1
−
1
View file @
e21096a7
...
...
@@ -97,7 +97,7 @@ public class testMario {
// Change l'image de fond
affiche
.
decor
.
changeImage
(
"background2.jpg"
);
// Passage à une vue non subjective
Repere
.
isSubjective
=
tru
e
;
Repere
.
isSubjective
=
fals
e
;
// Test to change the image
//monMonde.balle.sprites.assignNewImage("hero2.png");
...
...
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