Enno Rehling
d802f6ea67
cppcheck: reduce variable scope.
2018-02-25 17:28:42 +01:00
Enno Rehling
d15684a546
fix test_process_turn failure.
...
move turn global to calendar.
promote calendar module to kernel.
2018-02-14 20:01:36 +01:00
Enno Rehling
b5ea102372
cppcheck: scope reductions and a false positive.
2018-02-11 16:14:00 +01:00
Enno Rehling
398a258658
cppcheck: variable scopes, etc.
2018-02-11 15:57:31 +01:00
Enno Rehling
1035a98fd3
make attrib use a variant, not a custom union.
...
change attrib_type methods to take a variant, not the entire attrib.
2018-02-09 21:20:43 +01:00
Enno Rehling
5b61f895a2
further reduce teh amount of temporary storage required by the economy module.
2018-02-03 20:52:24 +01:00
Enno Rehling
6f7c8743b3
remove a lot of struct copying in the stupid expand function.
2018-02-03 20:45:19 +01:00
Enno Rehling
e1d33e55a4
refactor econ_request union for readability.
2018-02-03 20:24:16 +01:00
Enno Rehling
613c0edf2f
add most basic test coverage for cmd_loot
2018-02-03 15:25:03 +01:00
Enno Rehling
4247ef96b1
why are we using the short type?
2018-01-21 11:14:55 +01:00
Enno Rehling
3d69f4e372
start removing dependencies on potion_type.
...
use item_type where we can. does not compile, is WIP.
2018-01-14 17:40:48 +01:00
Enno Rehling
c8ee0db02d
stop using MIN and MAX
2017-12-30 08:58:50 +01:00
Enno Rehling
f98eab56c4
platform.h is only for WIN32 now.
...
replace MIN and MAX macros, they are BAD.
2017-12-29 06:13:28 +01:00
Enno Rehling
2ca236e68c
Add lua tests for ROUTE.
2017-12-10 20:54:02 +01:00
Enno Rehling
17ee0e50b6
cppcheck warnings and scope reductions.
2017-12-08 21:08:11 +01:00
Enno Rehling
3864a00482
remove stealing from economy.c (that file is too big).
2017-12-04 20:01:08 +01:00
Enno Rehling
05425b5101
pull economy requests into header, rename the struct.
2017-12-04 19:20:48 +01:00
Enno Rehling
34808a25c5
Merge branch 'develop'
2017-11-09 18:04:41 +01:00
Enno Rehling
96ff0815c4
newterrain sucks.
2017-11-05 19:15:43 +01:00
Enno Rehling
12646f726a
Add a failing test for bug 2379.
2017-11-05 15:11:02 +01:00
Enno Rehling
79aecf21b5
Merge branch 'develop'
2017-10-18 19:40:00 +02:00
Enno Rehling
e2c7b2c711
merge with master, which was far behind
2017-10-15 20:32:19 +02:00
Enno Rehling
333ef06fef
hackish optimization for STUDY orders
2017-10-13 19:33:29 +02:00
Enno Rehling
1b53128e1a
BUG 2366: Fix cansee for seen_spell regions.
2017-10-10 20:24:20 +02:00
Enno Rehling
455e03fa05
try and make coverity understand the equipment trie.
...
shorten names.
2017-09-17 20:42:43 +02:00
Enno Rehling
a8bfa5e095
try fixing familars without a mage.
2017-08-31 21:19:25 +02:00
Enno Rehling
8517857d55
BUG 2361: familiars cannot forget magic.
...
https://bugs.eressea.de/view.php?id=2361
2017-08-27 19:55:04 +02:00
Enno Rehling
2dd159841e
Merge branch 'master' into develop
2017-08-24 16:47:24 +02:00
Enno Rehling
fc4bde47f6
kill the old curses enum and oldcursename.
2017-08-21 20:48:00 +02:00
Enno Rehling
7985ebe511
replace ct_find calls with constants.
...
reorder a lot of includes.
2017-08-21 20:18:19 +02:00
Enno Rehling
c99e92db20
kill curse cache logic, it was a bad idea.
...
ct_find is almost never what we want to do.
2017-08-21 19:43:35 +02:00
Enno Rehling
4291c4de3d
BUG 2353: Segen der Erde produziert zu viel Silber
...
https://bugs.eressea.de/view.php?id=2353
In E3 gibt es legazy-attribute mit falschem Effekt, ignorieren.
2017-08-06 18:52:59 +02:00
Enno Rehling
0593378df0
Merge branch 'master' into develop
2017-06-24 22:10:05 +02:00
Enno Rehling
1e78414562
BUG 2344: GIB KOMMANDO und ! Präfix
2017-06-24 22:02:07 +02:00
Enno Rehling
1273abb967
Getrennte Befehle fuer PFLANZE und ZUECHTE
2017-06-24 13:36:18 +02:00
Enno Rehling
18daa9db2f
entirely remove RC_SPELL
2017-05-24 08:52:19 +02:00
Enno Rehling
9d5369ff1e
coverity: unintended integer division
2017-05-06 16:48:32 +02:00
Enno Rehling
898c12e99a
XML construction elements never have a building.
...
required buildings are encoded by RMT_PROD_REQUIRE.
improved error messaging.
2017-05-06 15:53:21 +02:00
Enno Rehling
976b23be72
refactor E3 to use the same raindance/harvest spells as E2.
...
only indirect effects are different.
2017-04-30 21:39:08 +02:00
Enno Rehling
7a289ceb86
simplify building_taxes, eliminate dead lua callbacks.
2017-04-29 19:21:48 +02:00
Enno Rehling
bdc7457a08
additional testing for largestbuilding and comparisons.
2017-04-28 21:30:05 +02:00
Enno Rehling
1112890293
use building_taxes everywhere.
...
make it return an integer, not double.
2017-04-28 20:10:20 +02:00
Enno Rehling
a313e78de5
move building names from function to construction data.
2017-04-26 21:44:24 +02:00
Enno Rehling
50eb35edf6
unused variable
2017-04-02 15:50:29 +02:00
Enno Rehling
e72155a563
WIP: reimplemented production modifiers.
...
The system itself seems to work, but some Lua tests are still failing.
2017-04-02 14:43:53 +02:00
Enno Rehling
4aa26343f6
the LOMEM define has never been used, kill it.
2017-04-01 20:08:04 +02:00
Enno Rehling
ed99f60186
decluttering settings.h
2017-03-31 21:37:30 +02:00
Enno Rehling
d99090ac67
remove additional unused macro constants
2017-03-31 21:29:37 +02:00
Enno Rehling
57ae21a823
remove an obsolete always-true constant
2017-03-31 21:26:07 +02:00
Enno Rehling
f941c5552f
remove RF_SELECT code from split_allocations.
...
the flag was only ever written, never read.
2017-03-23 19:32:17 +01:00
Enno Rehling
485e8f0ce4
Revert "add failing test for skill bonus from mine, start work"
...
This reverts commit ab87b1da85
.
2017-03-23 19:28:56 +01:00
Enno Rehling
ab87b1da85
add failing test for skill bonus from mine, start work
2017-03-23 18:51:30 +01:00
Enno Rehling
17145eaf10
make region:set_resource do the right thing
...
also for adamantium
2017-03-22 20:37:09 +01:00
Enno Rehling
4c67e0603b
remove attribs from rtype (it's only in rtype->construction that we use it?)
...
test to verify that mine bonus for iron works as advertised.
change the oder of arguments for faction.create (race is the only thing not optional).
2017-03-17 22:46:10 +01:00
Enno Rehling
7022ae05bd
Merge branch 'master' into develop
...
Conflicts:
src/kernel/item.c
src/modules/arena.c
2017-03-06 22:20:22 +01:00
Enno Rehling
4d07782e7d
Merge branch 'master' into develop
...
Conflicts:
scripts/tests/e2/init.lua
scripts/tests/e3/init.lua
src/economy.c
src/economy.test.c
2017-03-06 06:27:31 +01:00
Enno Rehling
5675ef6091
clean and extend the enum of resources.
2017-03-05 11:10:59 +01:00
Enno Rehling
b0baba4405
bug 2290: sawmill bonus was broken.
...
not pleased with the test, which is in lua only.
https://bugs.eressea.de/view.php?id=2290
2017-03-02 19:21:11 +01:00
Enno Rehling
d4b973fea4
remove resource_limit struct indirection.
2017-02-26 13:55:19 +01:00
Enno Rehling
c3b0b9e8b3
fix missing limit-flags.
2017-02-26 13:47:22 +01:00
Enno Rehling
0738090f28
no more funpointers in resource_limit.
...
change how resource limits in lua are called.
2017-02-26 13:19:47 +01:00
Enno Rehling
6031dff685
resource_limit.value is always zero, never initialized. kill it.
2017-02-25 19:50:32 +01:00
Enno Rehling
1498f2e1d7
refactor rawmaterial_type.
...
still have to decide if we need it at all.
2017-02-22 21:10:22 +01:00
Enno Rehling
ce2ea95880
begin refactoring limited resources.
2017-02-22 20:28:34 +01:00
Enno Rehling
4e5f1d05ce
Be very strict about C standards.
...
Compile with -std=c89 in gcc.
remove all // comments (they are nice, but unnecessary).
variables only declared at start of block.
various pedantery.
backwards compatible va_copy for pre-C99 gcc.
2017-02-18 21:15:14 +01:00
Enno Rehling
aee68fbd0f
github issue #658
...
MACHE 1 EISEN use 1 iron even with savings.
2017-02-18 11:19:42 +01:00
Enno Rehling
2328975dc2
do not use floats for material-save.
...
abusing variants for storing short fractions.
remove unused RMF_SAVERESOURCE.
2017-02-17 21:45:10 +01:00
Enno Rehling
a624915a06
error message if building is required.
...
was broken in recent commit.
also fix reference counts.
2017-02-16 20:26:34 +01:00
Enno Rehling
a5dfe12d48
initialize variable
2017-02-16 19:38:09 +01:00
Enno Rehling
20ff8981df
trying to extract allocation modifiers into a separate function
2017-02-16 10:19:59 +01:00
Enno Rehling
50083fc668
BUG 2279: too many resources used.
...
diddling the resource-save formula until test passes.
2017-02-15 21:16:54 +01:00
Enno Rehling
5680057e7f
adding simple test for MAKE <ITEM>
2017-02-15 17:09:23 +01:00
Enno Rehling
08e14f3095
coverity warnings
2017-02-14 16:23:40 +01:00
Enno Rehling
bd836b76e1
channel XML race.parameters through a single, tested, function
2017-02-05 16:55:51 +01:00
Enno Rehling
0b3d15f4b3
eliminate unused other_cost parameter.
...
cost of other races is defined by their recruitcost.
2017-02-04 23:46:26 +01:00
Enno Rehling
b27e1a01aa
continued work for MSVC compilation
2017-01-10 18:07:36 +01:00
Enno Rehling
8b7dae6977
kill autoconf.h, replace platform.h for C99 compatibility work
2017-01-10 16:31:05 +01:00
Enno Rehling
cc227fb707
merge monster.c and monsters.c
...
move RCF_DESERT handling to monsters.c
2016-12-23 18:05:38 +01:00
Enno Rehling
925d65c206
move entertainmoney to economy
2016-11-22 12:22:07 +01:00
Enno Rehling
ec4060cb9a
fix curse-vigour calculation math.
...
also fix a ton of small other niggles from pvs-studio.
2016-11-20 19:08:39 +01:00
Enno Rehling
772bc427aa
Merge branch 'develop' of github.com:ennorehling/eressea into develop
2016-11-15 20:44:02 +01:00
Enno Rehling
c1f468ceb0
begin to declutter config.c
2016-11-15 20:43:36 +01:00
Enno Rehling
ce4a3c14b3
convert from atoi to atoip.
...
most numbers in commands cannot be negative.
2016-11-14 22:27:44 +01:00
Enno Rehling
29d072a186
remove the old ORCIFICATION code.
2016-11-13 17:13:59 +01:00
Enno Rehling
fec9945458
Fixing Bugs 2246 & 2251
...
parse error message for bad orders:
https://bugs.eressea.de/view.php?id=2251
report when TEMP-Units cannot recuit:
https://bugs.eressea.de/view.php?id=2246
2016-11-05 18:20:56 +01:00
Enno Rehling
467ffe2db0
include guard.h directly, not through laws.h
2016-11-01 22:11:10 +01:00
Enno Rehling
754ad78db7
WIP: remove GUARD_* flags.
...
TODO: does not compile
TODO: write new guard.test.c tests
2016-10-31 07:45:06 +01:00
Enno Rehling
eb7199450d
fix Linux compilation.
2016-10-30 09:47:18 +01:00
Enno Rehling
2c0f708d1b
WIP: remove at_guard, GUARD_TREES and GUARD_MINING
...
TODO: fix tests
TODO: write new guard coverage
2016-10-30 09:18:19 +01:00
Enno Rehling
9287d0c1b4
unused function
2016-10-07 22:06:47 +02:00
Enno Rehling
38721e2046
remove all mention of centaurs from the code and configuration
2016-10-07 19:33:50 +02:00
Enno Rehling
d3efc265c3
calculating income for dragons is no longer hard-coded
2016-10-04 09:14:49 +02:00
Enno Rehling
cbd1e8c457
Fixing https://bugs.eressea.de/view.php?id=2234
...
remove the MTF_VITAL materials flag.
remove remaining BLD_MAINTAINED vs BLD_WORKING code.
2016-10-01 18:34:38 +02:00
Enno Rehling
2c0f0bfc1e
reduce get_race calls by a few more
2016-09-22 15:51:11 +02:00
Enno Rehling
7d88dddcc3
Merge pull request #578 from ennorehling/cache-buiding-type
...
add an API for caching the results of bt_find
2016-09-19 20:14:27 +02:00
Enno Rehling
a7fbe4901b
eliminate old_race. make the catdragon act like a dragon.
2016-09-19 18:42:14 +02:00
Enno Rehling
d139ee08d1
caching building_type in economy code
2016-09-19 04:15:26 +02:00
Enno Rehling
b3c31856aa
add (failing) test for recruiting into existing units.
2016-09-18 11:34:54 +02:00
Enno Rehling
3a438ffd4f
I have questions about this
2016-09-10 21:12:19 +02:00
Enno Rehling
d9e541843b
further reduce number of bt_find calls.
2016-08-30 09:36:09 +01:00