Enabling and Disabling Your RCI Spawning

Learn here how to create and use plugins.

Moderator: Plugin Moderators

User avatar
KINGTUT10101
1,000,000 inhabitants
Reactions:
Posts: 2220
Joined: 07 Jul 2016, 22:50
Location: 'Merica
Plugins: Showcase Store
Version: Beta
Contact:

Plugin Creator

Platform

Enabling and Disabling Your RCI Spawning

#1

Post by KINGTUT10101 »

In this post I'll be explaining how to enable or disable the spawning of your RCI plug-ins that have this code. The reason why it's useful is because it can be changed in-game. Unfortunately, it won't remove any buildings, it'll just prevent more from spawning. Anyways, here's what you will have to do. If you would like to see this trick in action before you attempt it, here's is my plug-in pack that uses this it:
https://sites.google.com/site/theotownm ... fects-pack

Step 1:
Create a building that will enable and disable the RCI buildings. This building doesn't need any special code or anything. It can be any building you want. Just make sure to remember the ID because it'll become useful in step 2.

Step 2:
Next you will need to add an unlock requirement to the RCI buildings you want to enable or disable. You'll need to add this to your plug-ins:

Code: Select all

      "requirement": {
         "requirements": [
            {
               "data": {
                  "id": "YOUR ID HERE"
               },
               "type": "BUILDING"
            }
         ]
      },
Make sure that "YOUR ID HERE" is the ID of your building from step 1. After adding that code you now have to ability to enable and disable the spawning of your RCI plug-ins in-game with the press of a button. To enable spawning, just place the building from step 1 and to disable spawning destroy it.
Last edited by KINGTUT10101 on 31 Aug 2017, 20:25, edited 1 time in total.

User avatar
Lobby
Developer
Reactions:
Posts: 3705
Joined: 26 Oct 2008, 12:34
Plugins: Showcase Store
Version: Beta

Platform

Re: Enabling and Disabling Your RCI Spawning

#2

Post by Lobby »

That's actually a really interesting idea :bc

User avatar
CommanderABab
AB
Reactions:
Posts: 11086
Joined: 07 Jun 2016, 21:12
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Enabling and Disabling Your RCI Spawning

#3

Post by CommanderABab »

You could use it to freeze a city. :)

Post Reply Previous topicNext topic

Return to “Tutorials and Documentation”