File: Move_Fog.py

package info (click to toggle)
crossfire-maps 1.71.0-1
  • links: PTS
  • area: main
  • in suites: buster, jessie, jessie-kfreebsd, stretch
  • size: 211,128 kB
  • sloc: python: 7,656; ansic: 2,143; perl: 744; sh: 73; makefile: 6
file content (11 lines) | stat: -rw-r--r-- 258 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
import Crossfire,random,math
Params=Crossfire.ScriptParameters()
if Params=="Fog":
	whoami=Crossfire.WhoAmI()
	Rand=random.randint(0,8)
	if Rand!=0:
		whoami.Move(Rand)
	whoami.Speed*=1.5
	whoami.Weight-=1
	if whoami.Weight>=0:
		Crossfire.SetReturnValue(1)