From bb02aa00f974484d9a0d27a30de58d576c9121db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Heredero?= Date: Thu, 16 Jun 2022 22:09:17 +0200 Subject: [PATCH] polish --- Data/Battle/Fight/physique.csv | 2 +- src/Entity/Player.java | 2 +- src/Screen/ScreenEnd.java | 6 ------ src/Text/TextEnemy.java | 10 ++++------ src/testYann.java | 13 ------------- 5 files changed, 6 insertions(+), 27 deletions(-) diff --git a/Data/Battle/Fight/physique.csv b/Data/Battle/Fight/physique.csv index c4cc64e..efd9f44 100644 --- a/Data/Battle/Fight/physique.csv +++ b/Data/Battle/Fight/physique.csv @@ -1,4 +1,4 @@ Quelle est l'équation de la position en fonction du temps ?;x(t) = (1/2)at^2 + vt + x;x(t) = vt + x;v(t) = at + v;x(t) = at^2 + vt + x;100 -Comment appelle-t-on la constante dans la formule pour calculer la force de d'attraction ?;la constante de gravitation;la constante de gravité;G = 5.674184;elle est valable dans tout l'univers ;50 +Comment appelle-t-on la constante dans la formule pour calculer la force d'attraction ?;la constante de gravitation;la constante de gravité;G = 5.674184;elle est valable dans tout l'univers ;50 Quelle est la valeur de la constante de gravitation ?;G = 6.674184;G = 5.674184;G = 0.674184;G = 10 (dans notre univers);75 Quelle est l'équation de la quantité de mouvement ?;P = m*v;A = t*a;S = u/r;H = k^2-f;75 diff --git a/src/Entity/Player.java b/src/Entity/Player.java index 314f97d..856b614 100644 --- a/src/Entity/Player.java +++ b/src/Entity/Player.java @@ -70,7 +70,7 @@ public class Player extends Character{ turn(goalDirection); System.out.println("It's a enemy !!"); } else { - setSpeed(sm.getSpeed(nextCell)*3); //TODO remove x3 + setSpeed(sm.getSpeed(nextCell)); //TODO remove x3 go(goalDirection); } } else { diff --git a/src/Screen/ScreenEnd.java b/src/Screen/ScreenEnd.java index 8627ab6..039c26a 100644 --- a/src/Screen/ScreenEnd.java +++ b/src/Screen/ScreenEnd.java @@ -1,20 +1,14 @@ package Screen; import com.badlogic.gdx.Gdx; -import com.badlogic.gdx.Input; import com.badlogic.gdx.files.FileHandle; import com.badlogic.gdx.graphics.Color; import com.badlogic.gdx.graphics.g2d.BitmapFont; import com.badlogic.gdx.graphics.g2d.freetype.FreeTypeFontGenerator; import com.badlogic.gdx.graphics.g2d.freetype.FreeTypeFontGenerator.FreeTypeFontParameter; -import Control.Controller; import Entity.Player; -import Game.Battle; -import Main.PokeMudry; import Main.Settings; - -import ch.hevs.gdx2d.components.bitmaps.BitmapImage; import ch.hevs.gdx2d.components.screen_management.RenderingScreen; import ch.hevs.gdx2d.lib.GdxGraphics; diff --git a/src/Text/TextEnemy.java b/src/Text/TextEnemy.java index 3e59660..fa4406c 100644 --- a/src/Text/TextEnemy.java +++ b/src/Text/TextEnemy.java @@ -1,11 +1,9 @@ package Text; -import java.util.Vector; - import Entity.Enemy; import Entity.Character.Direction; -import java.text.Normalizer; +import java.util.Vector; import java.util.Arrays; import java.util.Random; @@ -59,13 +57,13 @@ public class TextEnemy { // Creating object for Random class Random rd = new Random(); - + // Starting from the last element and swapping one by one. for (int i = a.length-1; i > 0; i--) { - + // Pick a random index from 0 to i int j = rd.nextInt(i+1); - + // Swap array[i] with the element at random index int temp = a[i]; a[i] = a[j]; diff --git a/src/testYann.java b/src/testYann.java index c267fa5..5850b47 100644 --- a/src/testYann.java +++ b/src/testYann.java @@ -1,16 +1,3 @@ - -import Text.*; -import java.util.Arrays; -import java.util.Collections; -import java.util.List; -import java.util.ListIterator; -import java.util.Random; -import java.util.RandomAccess; - - - - - class testYann{ public static void main(String[] args) {