Community Forums > Voobly General > General Discussion / Off Topic > How to disable a building on a custom map

How to disable a building on a custom map

 Denver17


Posted 31 March 2023 - 2:07 pm
market was unavailable in feudal age but I could build in castle age
Link | Reply | Quote
 Denver17


Posted 31 March 2023 - 2:08 pm
What now?;pout
Link | Reply | Quote
 +pablo@voobly

Community Patch Developer


Posted 31 March 2023 - 2:17 pm
Ah, right! We've only disabled the feudal one.

Repeat the process of defining the unit and moving the train button for units 116 and 137 as you did for unit 84. Remember to change the names to castle and imperial market so you have three different units modified.
Link | Reply | Quote
 Denver17


Edited 31 March 2023 - 2:26 pm by Denver17
ok thanks ;hearts
Link | Reply | Quote
 Denver17


Posted 31 March 2023 - 2:34 pm
Is it like this?

#const DARK_AGE_MARKET 84
#const FEUDAL_AGE_MARKET 116
#const CASTLE_AGE_MARKET 134
<PLAYER_SETUP>
random_placement
nomad_resources
ai_info_map_type NOMAD 1 0 0
effect_amount SET_ATTRIBUTE DARK_AGE_MARKET ATTR_TRAIN_BUTTON 255
effect_amount SET_ATTRIBUTE FEUDAL_AGE_MARKET ATTR_TRAIN_BUTTON 255
effect_amount SET_ATTRIBUTE CASTLE_AGE_MARKET ATTR_TRAIN_BUTTON 255
Link | Reply | Quote
 +pablo@voobly

Community Patch Developer


Posted 31 March 2023 - 2:46 pm
yes, that should be it. Plus the two constants for SET_ATTRIBUTE and ATTR_TRAIN_BUTTON
Link | Reply | Quote
 Denver17


Posted 31 March 2023 - 3:15 pm
we were unable to build the market, but the barbarians are still able to build the market!! Could you help me out!
Link | Reply | Quote
 +pablo@voobly

Community Patch Developer


Posted 31 March 2023 - 3:17 pm
what do you mean barbarians? The AI?
Link | Reply | Quote
 +pablo@voobly

Community Patch Developer


Edited 31 March 2023 - 4:17 pm by +pablo@voobly
Try to add also that the market is not built by a villager anymore:
Code:
#const ATTR_TRAIN_LOCATION 42 effect_amount SET_ATTRIBUTE DARK_AGE_MARKET ATTR_TRAIN_LOCATION -1
Link | Reply | Quote
 Denver17


Posted 31 March 2023 - 3:36 pm
Yes, the AI
Link | Reply | Quote
 +pablo@voobly

Community Patch Developer


Posted 31 March 2023 - 3:40 pm
Then try the train location thing. It's likely that the AI doesn't need the buttons to play and that's why it could still access the market. By removing the building from the villagers, it should be definitive.
Link | Reply | Quote
 Denver17


Posted 31 March 2023 - 4:09 pm
How to do that? I mean how to make villagers get removed from building market?
Link | Reply | Quote
 +pablo@voobly

Community Patch Developer


Posted 31 March 2023 - 4:16 pm
This:
Code:
#const ATTR_TRAIN_LOCATION 42 effect_amount SET_ATTRIBUTE DARK_AGE_MARKET ATTR_TRAIN_LOCATION -1
Link | Reply | Quote
 Denver17


Posted 31 March 2023 - 4:20 pm
ok sorry. I just replaced 255 with -1, forgot abt changing button to location
Link | Reply | Quote
 Denver17


Posted 31 March 2023 - 4:55 pm
No, But they are still building market, should I put both train button and train location?


Link | Reply | Quote
1[2]34
Displaying 16 - 30 out of 50 posts
Forum Jump:
2 User(s) are reading this topic (in the past 30 minutes)
0 members, 2 guests

What's popular right now: