Skip to content
Snippets Groups Projects
Commit bc9d55de authored by BuildTools's avatar BuildTools
Browse files

rangement du git

parent 9e4ccc97
Branches
No related merge requests found
fileFormatVersion: 2
guid: 81e39c4f6e44e7345849a14cbef3b3ea
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class LoseNature : MonoBehaviour
{
private bool lostLife = false;
private int nbFactory = 0;
public int damageByFactory = 20;
private void OnTriggerEnter2D(Collider2D collision)
{
if (collision.CompareTag("Player"))
{
if (!lostLife)
{
nbFactory = GameObject.FindGameObjectsWithTag("factory").Length;
Debug.Log("il pert de la vie: " + nbFactory * damageByFactory);
collision.GetComponent<PlayerNature>().LooseNature(damageByFactory * nbFactory);
this.lostLife = true;
}
}
}
}
fileFormatVersion: 2
guid: acdefb31f22c752ac90ddf2bf056e45c
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 1d113792a68e92533a5ae096013dedfd
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
public class Shopping : MonoBehaviour
{
private bool playerInRange;
private bool isBuy = false;
public Item sellItem = null;
//public GameObject[] itemForSale = new GameObject[2];
public List<GameObject> itemForSale = new List<GameObject>();
public GameObject panelEbutton;
public GameObject Ebutton;
public GameObject textEbutton;
public GameObject textEbuttonObject;
// Start is called before the first frame update
void Start()
{
panelEbutton.GetComponent<CanvasRenderer>().SetAlpha(0f);
Ebutton.GetComponent<CanvasRenderer>().SetAlpha(0f);
textEbutton.GetComponent<CanvasRenderer>().SetAlpha(0f);
textEbuttonObject.GetComponent<CanvasRenderer>().SetAlpha(0f);
}
// Update is called once per frame
void Update()
{
if (playerInRange)
{
switch (sellItem.id)
{
case 1:
textEbuttonObject.GetComponent<Text>().text = "Chaussures de marche";
break;
case 2:
textEbuttonObject.GetComponent<Text>().text = "Bâton de marche";
break;
case 3:
textEbuttonObject.GetComponent<Text>().text = "Réchaud";
break;
case 4:
textEbuttonObject.GetComponent<Text>().text = "Tente";
break;
}
}
if ((Input.GetKeyDown(KeyCode.E) || Input.GetKeyDown("joystick button 1")) && playerInRange && sellItem && itemForSale.Count > 0)
{
switch (sellItem.id)
{
case 1:
Dialog.instance.setSituation("boutiqueChaussure");
isBuy = true;
break;
case 2:
Dialog.instance.setSituation("boutiqueBaton");
isBuy = true;
break;
case 3:
Dialog.instance.setSituation("boutiqueRechaud");
isBuy = true;
break;
case 4:
Dialog.instance.setSituation("boutiqueTente");
isBuy = true;
break;
}
panelEbutton.GetComponent<CanvasRenderer>().SetAlpha(0f);
Ebutton.GetComponent<CanvasRenderer>().SetAlpha(0f);
textEbutton.GetComponent<CanvasRenderer>().SetAlpha(0f);
textEbuttonObject.GetComponent<CanvasRenderer>().SetAlpha(0f);
Inventory.instance.addItem(sellItem);
Debug.Log(sellItem.name.ToString() + " a bien ete ajouté a l'inventaire");
}
}
private void OnTriggerEnter2D(Collider2D collision)
{
if (collision.CompareTag("Player"))
{
playerInRange = true;
if (isBuy == false)
{
panelEbutton.GetComponent<CanvasRenderer>().SetAlpha(1f);
Ebutton.GetComponent<CanvasRenderer>().SetAlpha(1f);
textEbutton.GetComponent<CanvasRenderer>().SetAlpha(1f);
textEbuttonObject.GetComponent<CanvasRenderer>().SetAlpha(1f);
}
}
}
private void OnTriggerExit2D(Collider2D collision)
{
playerInRange = false;
panelEbutton.GetComponent<CanvasRenderer>().SetAlpha(0f);
Ebutton.GetComponent<CanvasRenderer>().SetAlpha(0f);
textEbutton.GetComponent<CanvasRenderer>().SetAlpha(0f);
textEbuttonObject.GetComponent<CanvasRenderer>().SetAlpha(0f);
}
}
fileFormatVersion: 2
guid: 3aca29e63a372841dabe9b809fff6d12
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
......@@ -3,19 +3,19 @@
## Objectifs pédagogiques
**Objectif pédagogique général** :
Apprendre au joueur comment c'est devellopé la randonner en Allemagne a partir de 1870, et pourquoi cette pratique c'est devellopé.
Apprendre au joueur comment c'est développé la randonnée en Allemagne à partir de 1870, et pourquoi cette pratique, c'est développé.
## Description des objectifs pédagogiques
**Mettre en avant le lien entre industrialisation et devellopement de la randonner**
- Notre jeux montre le paradoxe entre le besoin de nature et l'industrialisation
- Notre jeu montre le paradoxe entre le besoin de nature et l'industrialisation.
### Membre du projet tuteuré
- Tanguy Gimenez
- Melvyn FIscher
- Raffael DI-Pietro
- Raffael Di Pietro
- Valentin Bloch
### Objectifs d'un projet tuteuré
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment