Compare commits

..

2 Commits

Author SHA1 Message Date
MOISOIU Stefan-Mihai
c15787681f Merge branch 'main' of https://titi.koxi.nl/blodat/projet-dev 2026-03-16 16:17:38 +01:00
MOISOIU Stefan-Mihai
5a58534a40 fix niveaux 2026-03-16 16:17:30 +01:00
3 changed files with 12 additions and 13 deletions

View File

@@ -6,42 +6,41 @@ import java.util.List;
public class GestionnaireNiveau { public class GestionnaireNiveau {
public static final int FRAMES_PAR_NIVEAU = 25 * 10; // 10s a 25 FPS (timer 40ms) public static final int FRAMES_PAR_NIVEAU = 25 * 10; // 10 secondes
private final List<Niveau> niveaux = new ArrayList<>(); private final List<Niveau> niveaux = new ArrayList<>();
private int indexNiveau = 0; private int indexNiveau = 0;
private int framesDepuisDebut = 0; private int framesDepuisDebut = 0;
private int framesDansNiveau = 0; private int framesDansNiveau = 0;
// Duree du fade en frames private static final int DUREE_FADE = 25 * 3; // 3 secondes
private static final int DUREE_FADE = 75; // 3 secondes
public GestionnaireNiveau() { public GestionnaireNiveau() {
// Niveau 1 : lisse, cercle large // Niveau 1
niveaux.add(new Niveau(1, niveaux.add(new Niveau(1,
new Color(0, 73, 220), new Color(112, 158, 251),
8, 1 / 80.0, 80, 100, 500)); 8, 1 / 80.0, 80, 100, 500));
// Niveau 2 // Niveau 2
niveaux.add(new Niveau(2, niveaux.add(new Niveau(2,
new Color(75, 0, 180), new Color(187, 138, 255),
10, 1 / 60.0, 60, 100, 500)); 10, 1 / 60.0, 60, 100, 500));
// Niveau 3 // Niveau 3
niveaux.add(new Niveau(3, niveaux.add(new Niveau(3,
new Color(83, 30, 39), new Color(255, 106, 132),
12, 1 / 40.0, 50, 100, 500)); 12, 1 / 40.0, 50, 100, 500));
// Niveau 4 // Niveau 4
niveaux.add(new Niveau(4, niveaux.add(new Niveau(4,
new Color(20, 100, 40), new Color(191, 255, 207),
14, 1 / 30.0, 40, 100, 500)); 14, 1 / 35.0, 40, 100, 500));
// Niveau 5 : chaos, cercle petit // Niveau 5
niveaux.add(new Niveau(5, niveaux.add(new Niveau(5,
new Color(30, 30, 30), new Color(30, 30, 30),
16, 1 / 20.0, 30, 100, 500)); 15, 1 / 30.0, 30, 100, 500));
} }
public void mettreAJour() { public void mettreAJour() {

View File

@@ -8,7 +8,7 @@ import java.util.ArrayList;
public class Ligne extends ObjetGraphique { public class Ligne extends ObjetGraphique {
protected int nbSegments = 80; protected int nbSegments = 50;
protected Segment SegCourant; protected Segment SegCourant;
protected ArrayList<Segment> listeSegments = new ArrayList<Segment>(); protected ArrayList<Segment> listeSegments = new ArrayList<Segment>();

View File

@@ -7,7 +7,7 @@ public class Niveau {
public final int numero; public final int numero;
public final Color couleurFond; public final Color couleurFond;
public final double vitesseScroll; public final double vitesseScroll;
public final double noiseFrequence; // vitesse d'avancement dans le noise public final double noiseFrequence;
public final double rayonCercle; public final double rayonCercle;
public final double limiteHaut; public final double limiteHaut;
public final double limiteBas; public final double limiteBas;