forked from github/server
prevent buildings in regions that should not have any (simple hack)
This commit is contained in:
parent
f934772a66
commit
482a39db6d
|
@ -4759,8 +4759,8 @@
|
|||
<arg name="region" type="region"/>
|
||||
<arg name="command" type="order"/>
|
||||
</type>
|
||||
<text locale="de">"$unit($unit) in $region($region): '$order($command)' - So etwas kann man nicht bauen."</text>
|
||||
<text locale="en">"$unit($unit) in $region($region): '$order($command)' - You cannot build such a thing."</text>
|
||||
<text locale="de">"$unit($unit) in $region($region): '$order($command)' - So etwas kann man hier nicht bauen."</text>
|
||||
<text locale="en">"$unit($unit) in $region($region): '$order($command)' - You cannot build this here."</text>
|
||||
</message>
|
||||
<message name="error220" section="errors">
|
||||
<type>
|
||||
|
@ -4769,7 +4769,7 @@
|
|||
<arg name="command" type="order"/>
|
||||
</type>
|
||||
<text locale="de">"$unit($unit) in $region($region): '$order($command)' - Im astralen Nebel konnte niemand entdeckt werden."</text>
|
||||
<text locale="en">"$unit($unit) in $region($region): '$order($command)' - Noone could be seen in th astral fog."</text>
|
||||
<text locale="en">"$unit($unit) in $region($region): '$order($command)' - Noone could be seen in the astral fog."</text>
|
||||
</message>
|
||||
<message name="gbdream_noteach" section="errors">
|
||||
<type>
|
||||
|
|
|
@ -873,6 +873,11 @@ build_building(unit * u, const building_type * btype, int want, order * ord)
|
|||
cmistake(u, ord, 221, MSG_PRODUCE);
|
||||
return;
|
||||
}
|
||||
if (r->terrain->max_road<=0) {
|
||||
/* special terrain, cannot build */
|
||||
cmistake(u, ord, 221, MSG_PRODUCE);
|
||||
return;
|
||||
}
|
||||
if (btype->flags & BTF_ONEPERTURN) {
|
||||
if(b && fval(b, BLD_EXPANDED)) {
|
||||
cmistake(u, ord, 318, MSG_PRODUCE);
|
||||
|
|
|
@ -23,7 +23,7 @@ extern "C" {
|
|||
#endif
|
||||
|
||||
/* diverse Flags */
|
||||
/* Strassen können gebaut werden, wenn max_road > 0 */
|
||||
/* Strassen und Gebäude können gebaut werden, wenn max_road > 0 */
|
||||
#define LAND_REGION (1<<0) /* Standard-Land-struct region */
|
||||
#define SEA_REGION (1<<1) /* hier braucht man ein Boot */
|
||||
#define FOREST_REGION (1<<2) /* Elfen- und Kampfvorteil durch Bäume */
|
||||
|
|
Loading…
Reference in New Issue