J'out / destroy constructions

heya, quick question,

i remember that @tommyZZM made a code where he was able to deconstruct dead tanks etc.
but i kinda lost it.

does anyone know how that can be replicated?

i would have liked to do something similar, but for rendinsts and mines.

like, if you see an anti tank mine as rifleman, you can deconstruct it.
or, locked doors that requires to be destroyed through the J function.

tried to find the blk over the official, but it doesn’t seems the ones i unpack had it. (… and it kind would require me other 3 years to unpack other blkx since my program is very slow )

and, how can i tweak the parameter so that engineers are faster in doing that.

cheers.

1 Like

Probably need just add base_fortification_build postfix template. And set buildingRadius property.

Need to edit building_destroy__maxTimeToDestroy property.

They will still explode, but you can defuse it from a safe distance.

2 Likes

cheers :pray:

that’s… less than ideal.

but perhaps that will do.

2 Likes

tank wreckage auto shred codes

big_action_wreck_tank{
  _use:t="replicating"
  _use:t="big_action_vehicle_builded_no_shred"
  _use:t="base_vehicle"
  _use:t="animchar"
  _use:t="bonfire_effect_no_occluders"
  _use:t="fire_timings"
  _use:t="base_tank"
  _use:t="dead_entity"
  // _use:t="big_action_simple_unlimited_item_dropper"
  _use:t="big_action_fortification_build"
  building_menu__text:t="wreckage"
  building_destroy__maxTimeToDestroy:r=30.0
  squad:i=-1
  team:i=-1
  animchar__res:t="t_26_1940_char"
  collres__res:t="t_26_1940_collision"
  vehicle_net_phys__blk:t="gamedata/gen/units/tanks/t_26_1940.blk:VehiclePhys"
  particle_phys__blk:t="gamedata/suspension/empty.blk"
  dmg_animchar__res:t="t_26_1940_dmg_char"
  xray_resource__modelName:t="t_26_1940"
  effect__name:t="fire_tank_small_cmps_fx"
  fire_source__startTime:r=0.0
  fire_source__fullForceTime:r=180.0
  fire_source__maxFullForceTime:r=187.0
  fire_source__fadeTime:r=6.0
  fire_source__scale:r=1.29
  item__name:t="received/vehicle"
  ri_extra__hasCollision:b=no
  // item_drop_timer__delay:r=179.0

  // "unlimitedItemContainer:list<t>"{
  //   item:t="envir_destr_basic_small_effect"
  //   item:t="envir_destr_big_action_wreck_tank_effect"
  // }

  "humanAdditionalCollisionChecks:tag"{
  }

  "phys_vars__skipVisibilityCheck:tag"{
  }

  "vehicle__isExplosionFatal:b"{
    _tags:t="server"
    value:b=no
  }

  dmg_animchar{
    _tags:t="render"
  }

  _group{
    _tags:t="render"

    "visual_dmg_remap__partIdToNodeIdMain:list<i>"{
    }

    "visual_dmg_remap__partIdToNodeIdDmg:list<i>"{
    }

    "visual_dmg_remap__partIdToNodeIdDstr:list<i>"{
    }

    "visual_dmg_remap__collNodeIdToNodeIdMain:list<i>"{
    }

    "visual_dmg_remap__collNodeIdToNodeIdDmg:list<i>"{
    }

    "visual_dmg_remap__collNodeIdToNodeIdDstr:list<i>"{
    }
  }

  _group{
    _tags:t="input"

    "vehicle__steerTips:list<t>"{
      tip:t="Vehicle.Brake"
      tip:t="Vehicle.Accel"
      tip:t="Vehicle.Steer"
      tip:t="Vehicle.Throttle"
    }
  }

  _group{
    _tags:t="render"
    burnt_tank_overlay_res:t="burnt_tank_overlay"
    burnt_tank_overlay_var:t="burnt_tank_camo"

    "burnt_tank_overlay:SharedTexHolder"{
    }
  }

  _group{
    _tags:t="render"
    highlight_collision__color:p4=1.0, 0.0, 0.0, 1.0

    "highlight_collision__nodes:list<i>"{
    }
  }

  cockpit_animchar_res_preload{
    _tags:t="gameClient"
  }

  "animchar__objTexReplace:object"{
  }

  "animchar__objTexSet:object"{
  }

  "attach_decorators__templates:array"{
  }

  "attach_decorators__entities:list<eid>"{
  }

  "fire_source:tag"{
  }

  "zombieTriggerable:tag"{
  }

  "dmgzone__burningOffender:eid"{
  }
}
big_action_wreck_tank_100s{
  _use:t="big_action_wreck_tank"
  fire_source__fullForceTime:r=80.0
  fire_source__maxFullForceTime:r=100.0
}
base_tank{
  _override:b=yes
  entity__recreateToOnDeath:t="big_action_wreck_tank"
}
2 Likes

I don’t think this is possible at the moment, as mine entities will explode immediately when they disappear, even if they are pulled from the menu in the editor.

It may be necessary to write specific logic code to achieve


Possibly as an alternative gameplay implementation, perhaps some kind of special throwable could be made to detonate the mines in advance, from a safe distance.

2 Likes

yeah…

one of my original plans would backfire…

but still, more than helpful to get rid of dead tanks as makeshift obstacles or remove those indestructible czech anti tank traps :slight_smile:

2 Likes