clamp

    65La chaleur

    9Répondre

    Je le code suivant: new_index = index + offset if new_index < 0: new_index = 0 if new_index >= len(mylist): new_index = len(mylist) - 1 return mylist[new_index] Fondamentalement, je cal

    2La chaleur

    2Répondre

    Je rencontre un problème en utilisant Mathhelper.Clamp dans un jeu sur lequel je travaille. Voici un extrait du code qui me cause des problèmes: if (background.position.Y == 0) { player.position