Commit graph

14 commits

Author SHA1 Message Date
Kp 073f00974a Eliminate uses of the typedef struct X { ... } X; pattern
C++ does not require this pattern.

import re, fileinput
to = re.compile(r'^typedef struct ([a-z_A-Z]+)\s*{')
tc = re.compile(r'^}(.*?)\s*([a-z_A-Z]+);$')
osn = None
for line in fileinput.input(inplace=True):
	m = to.match(line)
	if m:
		osn = m.group(1)
		print 'struct %s\n{' % osn
		continue
	if osn:
		m = tc.match(line)
		if m:
			csn = m.group(2)
			if osn == csn:
				print '}%s;' % m.group(1)
				osn = None
				continue
			else:
				osn = None
	print line,
2013-12-28 22:48:07 +00:00
Kp a14d729e2f Use visited_segment_bitarray_t for set_segment_depths 2013-12-22 05:32:46 +00:00
Kp 6e1e9d0b24 Use visited_segment_bitarray_t for find_connected_distance 2013-12-22 05:32:29 +00:00
Kp 0de7bdc24c Use visited_segment_bitarray_t in trace_segs 2013-12-22 05:32:19 +00:00
Kp c31c67c587 Store selected segments in countarray object 2013-12-22 01:54:15 +00:00
Kp f817a7e603 Fix array understep when mapping exit tunnel 2013-12-20 03:21:40 +00:00
Kp ad90c245b6 Improve interaction of Del+F with normal map usage
Refactor edge computation into helper.

Let Automap_visited always be exactly what the player mapped normally.
This allows reversing Del+F.
2013-12-20 03:06:59 +00:00
Kp 7088720507 Use C++ array for Automap_visited 2013-12-15 18:46:42 +00:00
zico 2e407fa5a8 Removed short packets and added segment number to quaternion structure 2013-12-09 14:00:23 +01:00
Kp 75c229c6bf Normalize con_printf newline usage 2013-12-07 21:13:37 +00:00
Kp c70c6c98b3 Remove obsolete segment::degenerated flag
Shrinks Segments[] by 36000 bytes.
2013-11-24 23:08:32 +00:00
Kp 2714679284 Mark private functions static 2013-11-02 04:23:55 +00:00
Kp 95c1d784ef Remove unused function find_connected_distance_segments 2013-10-29 03:24:43 +00:00
Kp 8601ef255e Move similar/main/gameseg.c -> similar/main/gameseg.cpp 2013-10-05 21:35:58 +00:00
Renamed from similar/main/gameseg.c (Browse further)