the last of the item_type constants disappear.

This commit is contained in:
Enno Rehling 2005-10-29 15:03:18 +00:00
parent f6524ee015
commit baab10febe
5 changed files with 43 additions and 53 deletions

View File

@ -95,23 +95,6 @@ use_hornofdancing(struct unit * u, const struct item_type * itype,
return 0;
}
static resource_type rt_hornofdancing = {
{ "hornofdancing", "hornofdancing_p" },
{ "hornofdancing", "hornofdancing_p" },
RTF_ITEM,
&res_changeitem
};
item_type it_hornofdancing = {
&rt_hornofdancing, /* resourcetype */
0, 1, 0, /* flags, weight, capacity */
NULL, /* construction */
&use_hornofdancing,
NULL,
NULL
};
#define SPEEDUP 2
static int
@ -147,29 +130,10 @@ use_trappedairelemental(struct unit * u, int shipId,
return 0;
}
static resource_type rt_trappedairelemental = {
{ "trappedairelemental", "trappedairelemental_p" },
{ "trappedairelemental", "trappedairelemental_p" },
RTF_ITEM,
&res_changeitem
};
item_type it_trappedairelemental = {
&rt_trappedairelemental, /* resourcetype */
0, 1, 0, /* flags, weight, capacity */
NULL, /* construction */
NULL,
&use_trappedairelemental,
NULL
};
void
register_artrewards(void)
{
at_register(&at_peaceimmune);
it_register(&it_hornofdancing);
register_function((pf_generic)use_hornofdancing, "usehornofdancing");
it_register(&it_trappedairelemental);
register_function((pf_generic)use_trappedairelemental, "trappedairelemental");
register_function((pf_generic)use_hornofdancing, "use_hornofdancing");
register_function((pf_generic)use_trappedairelemental, "use_trappedairelemental");
}

View File

@ -18,9 +18,6 @@
extern "C" {
#endif
extern struct item_type it_hornofdancing;
extern struct item_type it_trappedairelemental;
extern void register_artrewards(void);
#ifdef __cplusplus

View File

@ -38,4 +38,11 @@
</item>
</resource>
<!-- HSE items -->
<resource name="studypotion">
<item weight="0">
<function name="use" value="use_studypotion"/>
</item>
</resource>
</resources>

View File

@ -1,6 +1,40 @@
<?xml version="1.0"?>
<resources>
<!-- art rewards -->
<resource name="trappedairelemental">
<item weight="1">
<function name="use" value="use_trappedairelemental"/>
</item>
</resource>
<resource name="hornofdancing">
<item weight="1">
<function name="use" value="use_hornofdancing"/>
</item>
</resource>
<!-- museum items -->
<resource name="museumexitticket">
<!-- you get your stuff back when leaving the museum -->
<item notlost="yes" weight="0">
<function name="use" value="use_museumexitticket"/>
</item>
</resource>
<resource name="museumticket">
<!-- you get your stuff back when leaving the museum -->
<item weight="0">
<function name="use" value="use_museumticket"/>
</item>
</resource>
<!-- gimmicks, etc. -->
<resource name="aog">
<!-- Amulett des Treffens -->
<item notlost="yes" weight="0"/>
</resource>
<resource name="ao_daemon">
<!-- summons igjarjuk -->
<item weight="0" score="6000" notlost="true" cursed="true">

View File

@ -1,11 +1,6 @@
<?xml version="1.0"?>
<resources>
<resource name="aog">
<!-- Amulett des Treffens -->
<item notlost="yes" weight="0"/>
</resource>
<!-- museum items -->
<resource name="museumexitticket">
<!-- you get your stuff back when leaving the museum -->
@ -36,13 +31,6 @@
</item>
</resource>
<!-- HSE items -->
<resource name="studypotion">
<item weight="0">
<function name="use" value="use_studypotion"/>
</item>
</resource>
<!-- xmas items -->
<resource name="mistletoe">
<!-- Sets the chance of escape in a fight to 100 percent -->