Delete the following line
Code: Select all
flags = "AutoOnCityCenter"
The help text:
Code: Select all
"), _("\
City center tiles with roads are automatically upgraded to railroads\
when you learn the Railroad technology.\
Code: Select all
flags = "AutoOnCityCenter"
Code: Select all
"), _("\
City center tiles with roads are automatically upgraded to railroads\
when you learn the Railroad technology.\
It's not just about movement. Railroad in Civ I also affects ALL tile produce. Many features in the civ1 ruleset are about nostalgia. Change to unit names from Civ II back to Civ I for example. Zero effect on gameplay, but nice for the memories.Ignatus wrote:Oh, and AI could not use railroads as more than just roads (as well as GOTOed units). This is so sick that I doubt if it woth putting in. (But well, how long ago one have played Civ1 not just out of nostalgie?)
Code: Select all
-- nef 2018/12/5
-- This lua script provides the feature in Civilization (Civ I) whereby
-- a city when razed pillages all improvements on the city center tile.
-- This defeats the exploit of getting a free bridge before knowing
-- the bridge building technology.
-- based on city ruins (anon.)
function city_destroyed_callback(city, loser, destroyer)
city.tile:remove_extra("Railroad")
city.tile:remove_extra("Road")
city.tile:remove_extra("Irrigation")
city.tile:remove_extra("Mine")
-- city.tile:create_extra("Ruins", NIL)
-- continue processing
return false
end
signal.connect("city_destroyed", "city_destroyed_callback")
Code: Select all
reqs =
{ "type", "name", "range", "present"
"Tech", "Railroad", "Player", TRUE
"Extra", "Road", "Local", TRUE
"UnitFlag", "Settlers", "Local", TRUE
"TerrainClass", "Land", "Local", TRUE
"CityTile", "Center", "Local", FALSE
}
Not quite sure what you mean here. I presume something in fc3.0. I'm assuming fc2.6.x - i.e. simple ruleset fixes for fc2.6. More permanent long term changes are another matter. As for fc2.6 I tried thinking - it helped. Not quite ready to publish but the railroad problem is SOLVED. Details next week for a solution that emulates Civ I warts and all.Ignatus wrote:As I understand, we should play here with the action enabler for "Road", not with extra reqs.
Code: Select all
[extra_no_rr]
name = _("Roadonly")
category = "Natural"
causes = "Base"
graphic = "None"
graphic_alt = "-"
activity_gfx = "None"
act_gfx_alt = "-"
act_gfx_alt2 = "-"
rmact_gfx = "None"
rmact_gfx_alt = "-"
reqs =
{ "type", "name", "range", "present"
"Extra", "Railroad", "Local", FALSE
"CityTile", "Center", "Local", TRUE
}
; buildable = FALSE ; kills autooncitycenter
build_time_factor = 0 ; nearly useless: AGH has no idea
; of what an empty list means
hidden_by = "Road" ; disable this if you want to snoop
flags = "AutoOnCityCenter" ; works only if buildable = TRUE
helptext = _("\
A city center tile can only have a railroad if it is \
already there before the city is built.\
")
[base_no_rr]
extra = "Roadonly"
gui_type = "Other"
Code: Select all
reqs =
{ "type", "name", "range", "present"
"Tech", "Railroad", "Player", TRUE
"Extra", "Road", "Local", TRUE
"Extra", "Roadonly", "Local", FALSE
"UnitFlag", "Settlers", "Local", TRUE
"TerrainClass", "Land", "Local", TRUE
}
Code: Select all
"), _("\
City center tiles with roads are automatically upgraded to railroads\
when you learn the Railroad technology.\
Code: Select all
"), _("\
A railroad cannot be built on a city center tile, but may be there\
if built first.\
Code: Select all
-- nef 2019/01/04
-- use this as an example for any other extras
-- that are nobbled by "Buildable = FALSE"
-- (until fixed)
function nonew_railroad(city)
local tile = city.tile
if not tile:has_extra ("Railroad")
then tile:create_extra("Roadonly", NIL)
end
return false
end
signal.connect("city_built", "nonew_railroad")
Code: Select all
; Civ1 would allow building Hydro Plant if there`s either River OR Mountains
; but it is not possible to implement with current ruleset format.
Code: Select all
; Civ2 would allow building Hydro Plant if there`s either River OR Mountains
; but it is not possible to implement with current ruleset format.
Code: Select all
[extra_hydro]
name = _("Hydro")
category = "Natural"
causes = "Base"
graphic = "None"
activity_gfx = "None"
rmact_gfx = "None"
buildable = FALSE
helptext = _("\
Marks a tile that if next to a city will enable hydro plant \
and Hoover Dam\
")
[base_hydro]
extra = "Hydro"
gui_type = "Other"
Code: Select all
"Extra", "River", "Adjacent"
Code: Select all
"Extra", "Hydro", "Adjacent"
Code: Select all
function whole_map()
for tile
in whole_map_iterate()
do
local tname = tile.terrain:rule_name()
-- insert active code here
end
return false
end
signal.connect("map_generated", "whole_map")