Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
Labyrinthe-Perdu
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
Florian Gambirasio
Labyrinthe-Perdu
Commits
f9d41593
Commit
f9d41593
authored
1 year ago
by
HydroFlo
Browse files
Options
Downloads
Patches
Plain Diff
edit
parent
3308e142
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
S1.02/Jeu/classes/Labyrinthe.class
+0
-0
0 additions, 0 deletions
S1.02/Jeu/classes/Labyrinthe.class
S1.02/Jeu/src/Labyrinthe.java
+4
-5
4 additions, 5 deletions
S1.02/Jeu/src/Labyrinthe.java
with
4 additions
and
5 deletions
S1.02/Jeu/classes/Labyrinthe.class
+
0
−
0
View file @
f9d41593
No preview for this file type
This diff is collapsed.
Click to expand it.
S1.02/Jeu/src/Labyrinthe.java
+
4
−
5
View file @
f9d41593
...
...
@@ -408,7 +408,7 @@ class Labyrinthe extends Program{
return
tab
;
}
void
ajoutQuestion
(
String
[][]
file
,
int
nbAjout
){
//Permet d'ajouter nbAjout nouvelle Question
void
ajoutQuestion
(
String
[][]
file
,
int
nbAjout
,
String
cheminFichier
){
//Permet d'ajouter nbAjout nouvelle Question
String
[][]
newFile
=
new
String
[
length
(
file
,
1
)
+
nbAjout
][
length
(
file
,
2
)];
for
(
int
i1
=
0
;
i1
<
length
(
file
,
1
);
i1
++){
//copie le fichier de base
for
(
int
j1
=
0
;
j1
<
length
(
file
,
2
);
j1
++){
...
...
@@ -423,7 +423,7 @@ class Labyrinthe extends Program{
newFile
[
i
][
0
]=
intitu
;
newFile
[
i
][
1
]=
rep
;
}
saveCSV
(
newFile
,
"ressources/ListeQuestion.csv"
);
saveCSV
(
newFile
,
cheminFichier
);
}
...
...
@@ -628,9 +628,8 @@ class Labyrinthe extends Program{
if
(
equals
(
toLowerCase
(
ques
),
"o"
)){
print
(
"Combien voulez vous en ajouter ? : "
);
int
nbAjout
=
nbFromString
(
1
);
ajoutQuestion
(
questionTemp
,
nbAjout
);
ajoutQuestion
(
questionTemp
,
nbAjout
,
cheminFichier
);
questionTemp
=
load
(
cheminFichier
);
afficheStringTab
(
questionTemp
);
}
else
if
(
equals
(
toLowerCase
(
ques
),
"p"
)){
for
(
int
i
=
0
;
i
<
length
(
lab
,
1
);
i
++){
for
(
int
j
=
0
;
j
<
length
(
lab
,
2
);
j
++){
...
...
@@ -645,6 +644,7 @@ class Labyrinthe extends Program{
int
tailleLab
=
nbFromString
(
3
);
Salle
[][]
lab
=
genererLab
(
tailleLab
);
//genere le Layrinthe
String
[][]
tabScore
=
load
(
"ressources/score.csv"
);
print
(
"Voulez vous ajouter des questions pour les monstres ? oui (o), non (autre) : "
);
updateCSVQuestion
(
lab
,
"ressources/ListeQuestion.csv"
);
...
...
@@ -653,7 +653,6 @@ class Labyrinthe extends Program{
Question
[]
lQuestion
=
listeQuestion
(
"ressources/ListeQuestion.csv"
);
Question
[]
lQuestionBoss
=
listeQuestion
(
"ressources/ListeQuestionBoss.csv"
);
print
(
readFile
(
"ressources/img/Presentation.txt"
,
true
));
//affiche l'écran titre
String
lancer
=
readString
();
...
...
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