1. Code:
    private List<string> BuildProps = new List<string>();
                BuildProps.Add("door.double.hinged.metal");
                BuildProps.Add("door.double.hinged.toptier");
                BuildProps.Add("door.double.hinged.wood");
                BuildProps.Add("dropbox");
                BuildProps.Add("mailbox");
                BuildProps.Add("box.repair.bench");
                BuildProps.Add("cupboard.tool");
                BuildProps.Add("furnace.large");
                BuildProps.Add("furnace");
                BuildProps.Add("planter.large");
                BuildProps.Add("box.wooden.large");
    Code:
    Error while compiling: ControlProp.cs(32,18): error CS1519: Unexpected symbol `(' in class, struct, or interface member declaration
     
  2. It looks like you're creating a list outside a method (hence the "private") and I assume trying to add to it right after creating it. You'll have to either move the list into a method (and remove the private) or just add to it from inside of one. For example, add to the list using the hook Init(), like so:

    Code:
    private List<string> BuildProps = new List<string>(); //this is outside
    void Init()
    {
                BuildProps.Add("door.double.hinged.metal");
                BuildProps.Add("door.double.hinged.toptier");
                BuildProps.Add("door.double.hinged.wood");
                BuildProps.Add("dropbox");
                BuildProps.Add("mailbox");
                BuildProps.Add("box.repair.bench");
                BuildProps.Add("cupboard.tool");
                BuildProps.Add("furnace.large");
                BuildProps.Add("furnace");
                BuildProps.Add("planter.large");
                BuildProps.Add("box.wooden.large");
    }
    
    Edit:
    Here's an example of how to create a list with values already in it, if that's what you need or want to do: How to initialize a C# string list (List<string>) with many string values
     
  3. thank u :D
    [DOUBLEPOST=1518247516][/DOUBLEPOST]
    The plugin works but the players can still take control of doors. The part where it check if it contains that string doesnt seem to returning true when the list contains the the name of the door.

    Code:
            bool ContainsString(BaseEntity propi)
            {
                bool BB;
                BB = false;
                for (int i = 0; i < BuildProps.Count; i++)
                {
                    if (propi.ShortPrefabName == BuildProps[i])
                    {
                        BB = true;
                        return BB;
                    }
                }
                return BB;
            }
     
  4. Code:
    return BuildProps.Contains(propi.ShortPrefabName);