From e366b2b3db8aa85e627b756598504c3a86e86024 Mon Sep 17 00:00:00 2001 From: "Eric S. Raymond" Date: Fri, 2 Jan 2004 21:55:06 +0000 Subject: [PATCH] Slight code simplification. --- ski | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ski b/ski index 2dc49c8..df5ec8c 100755 --- a/ski +++ b/ski @@ -165,15 +165,12 @@ class SkiWorld: self.prob_ground = [0.0, 30.0, 70.0, 90.0] self.level_num = 0 - self.player_pos = LINE_LEN / 2 + self.player_pos = random.choice(range(LINE_LEN)) self.yeti = None self.icbm_pos = None self.demon_pos = None self.slope = [REP_SNOW] * LINE_LEN - # Initialize the player's position. - self.player_pos = random.choice(range(LINE_LEN)) - # Randomize the appearance probabilities. self.prob_tree[0] = (random.randint(0, 99)) / 500.0 + 0.05 self.prob_ice[0] = (random.randint(0, 99)) / 500.0 + 0.05 -- 2.43.0