File: anthill.cfg

package info (click to toggle)
frogatto-data 1.2%2Bdfsg-1
  • links: PTS, VCS
  • area: non-free
  • in suites: wheezy
  • size: 201,844 kB
  • sloc: python: 302; xml: 223; perl: 139; sh: 48; makefile: 13; ruby: 4
file content (81 lines) | stat: -rw-r--r-- 1,714 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
[object_type]
id="anthill"
on_child_spawned="[
	  remove_object(child),
	  set(attached_objects, [child]),
	  set(tmp.spawning, child)
	]"
on_end_normal_anim="[
	  set(vars.spawned_objects, filter(vars.spawned_objects, 'ant', ant.hitpoints > 0 and ant.x > context.vars.zone_x1 and ant.x2 < context.vars.zone_x2)),
	  animation('normal'),
	  if(size(vars.spawned_objects) < vars.max_objects,
	     set(vars.generation_counter, vars.generation_counter+1),
		 set(vars.generation_counter, 0)),
	  if(vars.generation_counter >= 5 and tmp.spawning,
	     [set(attached_objects, []), set(tmp.spawning, null()),
		  set(tmp.spawning.velocity_y, -400),
		  set(vars.spawned_objects, vars.spawned_objects + [tmp.spawning]),
		  set(tmp.spawning.zorder,0),
		  add_object(tmp.spawning)]),
	  if(vars.generation_counter >= vars.generation_time,
	     [spawn(if(vars.spawn_type, vars.spawn_type, 'ant_red'), midpoint_x, midpoint_y, facing, set(zorder,-2)),
		  set(vars.generation_counter, 0)])
	  ]"
zorder="-1"
	[vars]
	generation_counter="0"
	generation_time="20"
	max_objects="3"
	spawn_type="'ant_red'"
	spawned_objects="[]"
	zone_x1="0"
	zone_x2="0"
	[/vars]

	[editor_info]
	category="bugs"
		[var]
		name="zone_x1"
		type="x"
		value="x - 300"
		[/var]

		[var]
		name="zone_x2"
		type="x"
		value="x + 400"
		[/var]

		[var]
		name="max_objects"
		value="3"
		[/var]

		[var]
		name="generation_time"
		value="20"
		[/var]

		[var]
		name="spawn_type"
		type="text"
		value="'ant_red'"
		[/var]

	[/editor_info]

	[tmp]
	spawning="null()"
	[/tmp]

	[animation]
	duration="10"
	frame_info="0,20,3,1,170,764,36,12"
	frames="1"
	id="normal"
	image="compiled-2.png"
	rect="170,744,208,776"
	[/animation]

[/object_type]