//Oi mate, if ya here to sneak, steal or use my codes for reference please fockin' credit me and Vivy 'ey? We worked countless sleepless nights fo' this mate. If you still don't accept these kind term then so be it. Pray that karma will be the one getting you because I'll be the one praying for your safety if I found our who you are.

{
  "format_version": "1.21.0",
  "minecraft:entity": {
    "description": {
      "identifier": "attack:rumiaspike",
      "is_spawnable": false,
      "is_summonable": true,
      "is_experimental": true
    },
    "component_groups": {
      "tick": {
        "minecraft:timer": {
          "time": 2,
          "time_down_event": {
            "event": "despawn"
          }
        }
      },
      "despawn": {
        "minecraft:instant_despawn": {}
      }
    },
    "components": {
      "minecraft:timer": {
        "time": 1.0,
        "time_down_event": {
          "event": "hit"
        }
      },
      "minecraft:rideable": {
        "seat_count": 1,
        "passenger_max_width": 100.0,
        "pull_in_entities": false,
        "seats": [
          {
            "position": [ 0.0, 0.0,1.0 ],
            "min_rider_count": 1,
            "max_rider_count": 1,
            "rotate_rider_by": 0,
            "lock_rider_rotation": 0
          }
          ]
      },
        "minecraft:despawn": {
          "despawn_from_chance": true,
          "despawn_from_distance": {
          "max_distance": 200,
          "min_distance": 190
        }
        },
      "minecraft:conditional_bandwidth_optimization": {
        "default_values": {
          "max_optimized_distance": 80.0,
          "max_dropped_ticks": 7,
          "use_motion_prediction_hints": true
        }
      },
      "minecraft:scale": {
        "value": 1.0
      },
      "minecraft:type_family": {
        "family": [
          "projectile",
          "misc",
          "custom_attack",
          "custom_mob"
          ]
      },
      "minecraft:collision_box": {
        "width": 3,
        "height": 18
      },
      "minecraft:hurt_on_condition": {
        "damage_conditions": [
          {
            "filters": { "test": "in_lava", "subject": "self", "operator": "==", "value": true },
            "cause": "lava",
            "damage_per_tick": 4
          }
        ]
      },
      "minecraft:physics": {
      },
      "minecraft:pushable": {
        "is_pushable": false,
        "is_pushable_by_piston": true
      },
      "minecraft:damage_sensor": {
        "triggers": [
          {
            "deals_damage": false
          }
          ]
      },
      "minecraft:health": {
        "value": 10000,
        "max": 10000
      }
    },
    "events": {
      "minecraft:entity_spawned": {
        "sequence": [
          {
            "queue_command": {
              "command": [
                "fill ~3~~3 ~-3~18~-3 air",
                "tag @s add iframes"
                ]
            }
          }
        ]
      },
      "hit": {
        "queue_command": {
          "command": [
            "execute if entity @s positioned ~~3~ as @e[r=3,tag=!iframes] run scoreboard players set @s stamina -100",
            "execute if entity @s positioned ~~6~ as @e[r=2.5,tag=!iframes] run scoreboard players set @s stamina -100",
            "execute if entity @s positioned ~~9~ as @e[r=2,tag=!iframes] run scoreboard players set @s stamina -100",
            "execute if entity @s positioned ~~18~ as @e[r=1.5,tag=!iframes] run scoreboard players set @s stamina -100"
            ]
        },
        "add": {
          "component_groups": [
            "tick"
            ]
        }
      },
      "despawn": {
        "add": {
          "component_groups": [
            "despawn"
            ]
        }
      }
    }
  }
}