@@ -69,7 +69,7 @@ public static TemplateScene getInstance() {
6969 return instance ;
7070 }
7171
72- private Arrow arrow ;
72+ public Arrow arrow ;
7373
7474 /*
7575 */
@@ -251,22 +251,38 @@ else if(tutorialStage == 13) {
251251 tempBool = false ;
252252 }
253253 else if (tutorialStage == 14 && !tempBool ) {
254+ if (!shipTilemap .player .hasFireExtinguisher ) {
255+ arrow .position .x = entityManager .fireExtinguisher .position .x ;
256+ arrow .position .y = Gdx .graphics .getHeight ()-entityManager .fireExtinguisher .position .y -32 ;
257+ }
258+ else {
259+ tutorialStage ++;
260+ }
261+ tutorialText = "PICK UP EXTINGUISHER." ;
262+ glyphLayout .setText (FontManager .font_droidBb_40 , tutorialText );
263+ }
264+ else if (tutorialStage == 15 && !tempBool ) {
254265 boolean placeFire = true ;
255266 while (placeFire ) {
256267 Vector2 pos = new Vector2 ((int )((float )Math .random () * shipTilemap .getWidth ()), (int )((float )Math .random () * shipTilemap .getHeight ()));
257268 if (shipTilemap .getTileByPosition ((int )pos .x , (int )pos .y ).tileID == Tile .GroundTile .tileID ) {
258- shipTilemap .fireHandler .add (new Fire (new Vector2 (pos .x *32 +shipTilemap .offset .x - 4 , pos .y *32 +shipTilemap .offset .y )));
269+ shipTilemap .fireHandler .add (new Fire (new Vector2 (pos .x *32 +shipTilemap .offset .x , pos .y *32 +shipTilemap .offset .y )));
259270 placeFire = false ;
271+
272+ if (shipTilemap .player .hasFireExtinguisher ) {
273+ arrow .position .x = pos .x *32 +shipTilemap .offset .x ;
274+ arrow .position .y = Gdx .graphics .getHeight ()-(pos .y *32 +shipTilemap .offset .y +32 );
275+ }
260276 }
261277 }
262- arrow .position .x = -100 ;
263- arrow .position .y = -100 ;
264- tutorialText = "FIRE BROKE OUT. PICK UP EXTINGUISHER AND EXTINGUISH IT BY COMING NEAR IT." ;
278+ tutorialText = "FIRE BROKE OUT. EXTINGUISH IT BY COMING NEAR IT." ;
265279 glyphLayout .setText (FontManager .font_droidBb_40 , tutorialText );
266280 tempBool = true ;
267281 }
268- else if (tutorialStage >= 15 ) {
282+ else if (tutorialStage >= 16 ) {
269283 tutorialText = "GOOD JOB! YOU FINISHED TUTORIAL. PRESS SPACE FOR MENU." ;
284+ arrow .position .x = -100 ;
285+ arrow .position .y = -100 ;
270286 glyphLayout .setText (FontManager .font_droidBb_40 , tutorialText );
271287 }
272288 return ;
@@ -370,7 +386,7 @@ public void render(float delta) {
370386 }
371387 }
372388
373- if (tutorialStage >= 15 && GlobalShipVariables .tutorialMode ) {
389+ if (tutorialStage >= 16 && GlobalShipVariables .tutorialMode ) {
374390 if (Gdx .input .isKeyJustPressed (Input .Keys .SPACE )) {
375391 TemplateScene .shipTilemap .doorHandler .clear ();
376392 TemplateScene .shipTilemap .fireHandler .clear ();
0 commit comments