Code Duplication    Length = 12-12 lines in 2 locations

modules/bataille/app/controller/Batiment.php 2 locations

@@ 376-387 (lines=12) @@
373
						}
374
						
375
						//si ok on affiche le batiment
376
						if ($ok_construction === true) {
377
							$ressource = $this->getRessourceConstruireBatiment($this->all_batiment[$i], 0);
378
							
379
							$batiment_construire[] = [
380
								"nom_batiment_sql" => $this->all_batiment[$i],
381
								"nom_batiment" => $this->all_batiment_nom[$i],
382
								"ressource" => $ressource,
383
								"temps_construction" => $temps_construction,
384
								"width" => $taille_batiment[0],
385
								"height" => $taille_batiment[1]
386
							];
387
						}
388
					}
389
					else {
390
						$ressource = $this->getRessourceConstruireBatiment($this->all_batiment[$i], 0);
@@ 389-400 (lines=12) @@
386
							];
387
						}
388
					}
389
					else {
390
						$ressource = $this->getRessourceConstruireBatiment($this->all_batiment[$i], 0);
391
392
						$batiment_construire[] = [
393
							"nom_batiment_sql" => $this->all_batiment[$i],
394
							"nom_batiment" => $this->all_batiment_nom[$i],
395
							"ressource" => $ressource,
396
							"temps_construction" => $temps_construction,
397
							"width" => $taille_batiment[0],
398
							"height" => $taille_batiment[1]
399
						];
400
					}
401
				}
402
			}
403
			Bataille::setValues(["batiments_construire" => $batiment_construire]);