InvFoundation

Invulnerable foundation

Total Downloads: 694 - First Release: Aug 23, 2016 - Last Update: Mar 25, 2018

5/5, 5 likes
  1. You can't the plugin reverts it to default every time. Even when unloaded then loaded once changes made. Try it you will see
     
  2. You can change the message from the lang file, sorry about the name of the reference, it's NoPerm
     
  3. I did try to change it at least 20 times but each time the plugin is loaded the default lang file is made. no matter how I try to change it every time the plugin loads the default lang is made. I thought I had made that clear? Obviously not!
     
  4. I'll check on my way but it didn't appear before, i'll let you know
    [DOUBLEPOST=1511968386][/DOUBLEPOST]@PryMary after a test, it seem that all good, you can change the message, remember that you can't change the reference "NoPerm" but only the message
     
  5. that will be why it was reverting: "Anti-Foundation Wipe": "This Foundation Level Can Not Be Damaged!" is what i was trying to get it to display as it makes more sense than having: "No Perm": "This Foundation Level Can Not Be Damaged!" doesn't make much sense to me. It's fine I will leave it for if/when it can be changed :)
     
  6. There is one thing I have noticed is that the splash damage sensitivity is really high and triggers the message even when hitting the top of a wall section with a rocket. Is there anyway to stop the message on splash damage? But still keep the foundation protected?
     
  7. The message is displayed only if foundation is going to take damage, if it appear it's because foundation is supposed to take damage
     
  8. Can you protect the wall?
     
  9. Any chance there can be a detection for caves? Example: If the foundation is detected to be within a cave, InvFoundation = False? It's tiring to patrol the cave bases for those that block their entrance with a single foundation. Thanks :)
     
  10. sami37 updated InvFoundation with a new update entry:

    1.2.4

     

  11. You... Are... Awesome...
     
  12. I have setup that twig is decaying, but people building a twig bridge in water or land is not decaying. I guess due to this plugin? Is there a way to let twig foundations without any walls or stuff on it still decay?

    In other words: does OnEntityTakeDamage also handle decay damage?
     
  13. Get NoDecay plugin, and set twig to 0. Problem solved.
     
  14. Every damage goes to OnEntityTakeDamage, in the current state of plugin, your building should get damaged by decay, because decay act like when you shot something but the difference is that the "attacker" is not a player but i'll add a litle check for decay.

    Why he should use NoDecay, and why set to 0 if he is actually looking to decay the twig, also InvFoundation just act on foundation and not any other stuff, as decay act in every type of building block.
     
  15. sami37 updated InvFoundation with a new update entry:

    1.2.5

     
  16. I wanted to make foundation raids a lot less easier by changing the damages, but I don't seem to get it working. I've got this at this moment:
    Code:
    {
      "Allow Decay": true,
      "DamageList": {
        "Blunt": 1.0,
        "Bullet": 1.0,
        "Explosion": 1.0,
        "Slash": 1.0,
        "Stab": 1.0
      },
      "Exclude cave": true,
      "TierScalingDamage": {
        "Metal": 0.2,
        "Stone": 0.2,
        "TopTier": 0.5,
        "Twigs": 0.5,
        "Wood": 1.0
      },
      "UseBuildingOwner": false,
      "UseDamageScaling": true,
      "UseEntityOwner": false
    }
    but whatever I do, I always get the same amount of damage with a C4 or any other explosive... Tested with stone and metal
     
  17. Remember that if you are the owner of foundation, your damage will not be reduce in any way
     
  18. So what are these doing then?

    Code:
    "UseEntityOwner": false
    "UseBuildingOwner": false,
     
  19. Additionnal check for ownerID

    Code:
            bool IsOwner(BasePlayer player, BaseEntity targetEntity)
            {
                if (targetEntity == null) return false;
                if (targetEntity.OwnerID == player.userID) return true;
                BuildingBlock block = targetEntity.GetComponent<BuildingBlock>();
                if (block == null)
                {
                    RaycastHit supportHit;
                    if (Physics.Raycast(targetEntity.transform.position + new Vector3(0f, 0.1f, 0f), new Vector3(0f, -1f, 0f), out supportHit, 3f, colisionentity))
                    {
                        BaseEntity supportEnt = supportHit.GetEntity();
                        if (supportEnt != null)
                        {
                            block = supportEnt.GetComponent<BuildingBlock>();
                        }
                    }
                }
                if (block != null)
                {
                    if (UseBuildOwners)
                    {
                        if (BuildingOwners != null && BuildingOwners.IsLoaded)
                        {
                            var returnhook = Interface.GetMod().CallHook("FindBlockData", new object[] {block});
                            if (returnhook is string)
                            {
                                string ownerid = (string) returnhook;
                                if (player.UserIDString == ownerid) return true;
                            }
                        }
                    }
                    if (UseEntityOwner)
                    {
                        if (EntityOwner != null && EntityOwner.IsLoaded)
                        {
                            var returnhook = Interface.GetMod().CallHook("FindEntityData", new object[] {targetEntity});
                            if (returnhook is string)
                            {
                                string ownerid = (string) returnhook;
                                if (player.UserIDString == ownerid) return true;
                            }
                        }
                    }
                }
                return false;
            }
    
    [DOUBLEPOST=1521986390][/DOUBLEPOST]As far as i know it was usefull, but i'll remove it as EntityOwner do the same
     
  20. sami37 updated InvFoundation with a new update entry:

    1.2.6