TurretConfig

Moved

Total Downloads: 4,361 - First Release: Nov 3, 2015 - Last Update: May 13, 2017

5/5, 24 likes
  1. I still seem to be having issues with animal targeting. I updated to 2.0.4 and got a new config and turn animaloverride off but it still doesn't shoot them. There aren't any errors in the logs.
     
  2. Wulf can You fix flame tower - with marked no limit ammo it dont fire :/
    dunno what is wrong but think its becouse its placed without ammo so dont fire at all.

    And animal override dont work.
     
  3. nothing there..
    only for version 2.0.3:
    Code:
    06:05 [Error] Failed to call hook 'OnEntitySpawned' on plugin 'TurretConfig v2.0.3' (NullReferenceException: Object reference not set to an instance of an object)
    06:05 [Stacktrace]   at Oxide.Plugins.TurretConfig.InitializeTurret (.BaseCombatEntity turret, Single turretHealth, Boolean justCreated) [0x00000] in <filename unknown>:0 
      at Oxide.Plugins.TurretConfig.UpdateAutoTurret (.AutoTurret turret, Boolean justCreated) [0x00000] in <filename unknown>:0 
      at Oxide.Plugins.TurretConfig.OnEntitySpawned (.BaseNetworkable entity) [0x00000] in <filename unknown>:0 
      at Oxide.Plugins.TurretConfig.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x00000] in <filename unknown>:0 
      at Oxide.Plugins.CSharpPlugin.InvokeMethod (HookMethod method, System.Object[] args) [0x00000] in <filename unknown>:0 
      at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x00000] in <filename unknown>:0 
      at Oxide.Core.Plugins.Plugin.CallHook (System.String hook, System.Object[] args) [0x00000] in <filename unknown>:0
    but i see no single NRE in that log file after i installed v2.0.4.. and its strange, because i saw(and posted here) it flooding server console with red error message.
     
  4. Wulf

    Wulf Community Admin

    So likely not an issue then in 2.0.4. Your last log had v2.0.3 in it.
     
  5. Think here is the problem:
    Code:
    private void CheckAutoTurretAmmo(AutoTurret turret)
            {
                if (!infiniteAmmo) return;
                if (!permission.UserHasPermission(turret.OwnerID.ToString(), "turretconfig.infiniteammo")) return;            var items = new List<Item>();
                var projectile = turret.ammoType.GetComponent<ItemModProjectile>();
                turret.inventory.FindAmmo(items, projectile.ammoType);            int total = items.Sum(x => x.amount);            if (total < 1)
                {
                    turret.inventory.AddItem(turret.ammoType, 1);
                }
            }
    Ammo is set AutoTurretAmmo but not to FLAME ONE - with marked option UNLIMITED AMMO - not work at all i think becouse it dont know what ammo to put in to start shoot with unlimited ammo, and it works with unlimited on normal autoturrets.
     
    Last edited by a moderator: May 16, 2017
  6. Wulf

    Wulf Community Admin

    It would use fuel actually, not ammo, so it would require some slightly different changes I believe.
     
  7. if u want to be able to put ammo(lgf) into flame turrets with infinite ammo option enabled, change line 374 of the plugin from:
    Code:
    if (target is AutoTurret || target is FlameTurret)
    to
    Code:
    if (target is AutoTurret)
     
  8. thx v much it works perfect :)

    one tini problem still eat fuel on it hmm

    "Flame": {
    "arcs": {
    "turretconfig.default": 45.0
    },
    "defaultArc": 45.0,
    "defaultFlameHealth": 300.0,
    "defaultFlameRadius": 4.0,
    "defaultFlameRange": 8.0,
    "defaultFuelPerSec": 0.1,
    "defaultTriggerDuration": 5.0,
    "flameHealths": {
    "turretconfig.default": 300.0
    },
    "flameRadiuses": {
    "turretconfig.default": 4.0
    },
    "flameRanges": {
    "turretconfig.default": 8.0
    },
    "fuelPerSecs": {
    "turretconfig.default": 0.1
    },
    "triggerDurations": {
    "turretconfig.default": 5.0
     
    Last edited by a moderator: May 24, 2017
  9. any reason why changing ammo from say regular to HV or Inc/exp wont work? i change it back to regular. it works fine but cant seem to get other types to work with no errors too.
     
  10. same here it has never worked with diffrent kind of ammo always been default
     
  11. turrets dont seem to be shooting at animals even tho its in the config
     
  12. same lol
     
  13. Would it be possible to add a "respawn" option?
     
  14. im confused what do you need a respawn option for lol ? turrets dont respawn
     
  15. In order to add PVE. For example, putting turrets to keep the airport. And why not also enemies (NPC Core) and traps.
     
  16. oooh im with you now so you want the turrets to be respawned after they have been blown up for example so you dont have to keep placing them down ??
     
  17. Exactly ! You're with me now ;)
     
  18. Good evening. Can we define a turret as indescribable or make it respawnable?