`custom_marker` icon properties incorrectly in multiplayer games

custom_marker icon properties incorrectly in multiplayer games.

test case

entity{
  _template:t="custom_marker"
  transform:m=[[0.0105882, 0, 0.999944] [0, 1, -0] [-0.999944, 0, 0.0105882] [-677.651, 1.79962, -476.69]]
  custom_marker__icon:t="!ui/skin#building_bridge.svg"
  custom_marker__iconColor:c=255, 255, 255, 255
  custom_marker__iconSize:p2=23, 23
}

Currently unable to set icon, color and size

Although you set these values, they are in multiplayer games, note that in multiplayer games, these values ​​do not take effect


With solute this issue, maybe developer can apply replicating to custom_marker

Then dynamically generated entities can also have different icons by adding replicate

custom_marker{
   // …
   _extends:t="replicating"
   _replicated:t="custom_marker__icon"
   _replicated:t="custom_marker__iconColor"
   _replicated:t="custom_marker__iconSize"
}
3 Likes

Hey!

Try to add custom_marker__active:b=yes component

1 Like

Hello!
Need to do this, right?

entity{
  _template:t="custom_marker"
  transform:m=[[1, 0, 0] [0, 1, 0] [0, 0, 1] [732.145, 2.24945, 687.308]]
  custom_marker__icon:t="!ui/skin#skull.svg"
  custom_marker__iconColor:c=255, 255, 255, 255
  custom_marker__active:b=yes
}

It still show only red markers.


But should:
image
Sandbox portal post + scene code in download sources.
2023_08_30_19_56_41__2224.clog (1.3 МБ)

1 Like

entity can be placed and displayed correctly.

But can’t change its icon, color and size. They are always shown as red arrows.

I suggest that the attributes of this custom_marker should be fully replicated.

including its icon, color, team, active attributes etc.

I’ve come up with a lot of new features based on custom_marker that we can use it to make custom map markers by radioman.

And we can also make artillery marks appear only to teammates.

There are also small map missions markers like what we have in CRSRD.

Should be fixed in 0.4.8.73

2 Likes

Yes, tried, it has been fixed. Thx.


But currently the marker attribute yet can not be configure for the generated entity by entities.blk.

1 Like

what do you mean?

1 Like

for example adding a icon on capzone__bombTemplate on bomb_site

capzone__alwaysHide:b=yes
capzone__bombTemplate:t="custom_marker+bomb_site+bomb_site_radar_hardware_animchar_03_without_antenna"

When the bomb explodes, the icon will disappear

bomb_site_radar_hardware_animchar_03_without_antenna{
   _override:b=yes
  custom_marker__showForTeam:i=1
  custom_marker__icon:t="!ui/skin#item_tnt_block_exploder.svg"
  custom_marker__iconColor:c=255, 0, 0, 100
  custom_marker__iconSize:p2=20, 20
}

What is described is that the icon cannot be set currently in this case.


And I mainly want to add icons to the generated vehicles and builded entity by engineer, but this is just a small UI issue and it doesn’t affect too much.

mbs_stool_a{
  _override:b=yes
  _extends:t="resupply_for_ground_vehicle_zone"
  resupply_zone__team:i=2
  resupply_zone__resupplyFuel:b=yes
  sphere_zone__radius:r=36.0
  active:b=yes
  zone__icon:t="!ui/skin#bullets.svg"  // can't display in multiplayer games
  minimap__visibleRadius:r=3000.0
  minimap__visibleForAll:b=yes
  building_menu__image:t="medic_veteran" // can't display for teammate in multiplayer games, but if for enemy pin to the building it works
  hud_icon__image:t="medic_veteran"  // can't display in multiplayer games
  _tracked:t="building_menu__image"
  _tracked:t="hud_icon__image"
  _replicated:t="building_menu__image"
  _replicated:t="hud_icon__image"
  placeable_item__ownerTeam:i=2
  builder_info__team:i=-1

  // want to define by this 
  custom_marker__showForTeam:i=1
  custom_marker__icon:t="!ui/skin#medic_veteran.svg"
  custom_marker__iconColor:c=255, 255, 255, 100
  custom_marker__iconSize:p2=20, 20

  "buildByPlayer:eid"{
  }

  "dependsOnBuildingEid:eid"{
  }
}
ussr_rallypoint{
  _override:b=yes

  "additiveBuildings:array"{

    "item:object"{
      template:t="rally_point_respawn_base+forceRespawnPriority"
      tm:m=[[1.0, 0.0, 0.0] [0.0, 1.0, 0.0] [0.0, 0.0, 1.0] [0.0, 1.0, 0.0]]
    }

    "item:object"{
      // template:t="custom_marker+placed_medic_box_item+item_in_world+mbs_desktop_stuff_a_binoculars+replicating"
      template:t="placed_medic_box_item+item_in_world+mbs_desktop_stuff_a_binoculars+replicating"
      tm:m=[[1.0, 0.0, 0.0] [0.0, 1.0, 0.0] [0.0, 0.0, 1.0] [0.0, -0.2, 0.0]]
    }

    "item:object"{
      // template:t="custom_marker+placed_medic_box_item+item_in_world+bomb_site_radar_hardware_animchar_04+replicating"
      template:t="placed_medic_box_item+item_in_world+bomb_site_radar_hardware_animchar_04+replicating"
      tm:m=[[1.0, 0.0, 0.0] [0.0, 1.0, 0.0] [0.0, 0.0, 1.0] [0.5, -0.2, -0.3]]
    }
  }
}

Here is the currently running example on multiplayer games

Currently I’m using placed_medic_box_item + item_in_world to display icon.

But I can’t change it’s icon, it just shows up as a medbox in multiplayer (actually I have set his icon).

I hope custom_marker can help with this.


But I think this problem is not a particularly high priority.

These problems can be solved when the client can synchronize entities.blk.


Currently, Please give priority to solving another problem of tank_template+vehicle_template

bomb_site_radar_hardware_animchar_04{
  _override:b=yes
  _extends:t="custom_marker"
  minimap__visibleRadius:r=0.0
  minimap__visibleForAll:b=no
  building_menu__image:t="radio"
  hud_icon__image:t="radio"
  _tracked:t="building_menu__image"
  _tracked:t="hud_icon__image"
  _replicated:t="building_menu__image"
  _replicated:t="hud_icon__image"
  placeable_item__ownerTeam:i=1
  team:i=1
  custom_marker__showForTeam:i=1
  custom_marker__icon:t="!ui/skin#radioman.svg"
  custom_marker__iconColor:c=255, 255, 255, 255
  custom_marker__iconSize:p2=18, 18
  useful_box__maxUseCount:i=999999
  hud_icon__maxDistance:r=30.0
  useful_box__itemExistTag:t="item__repair_kit"
  useful_box__giveItem:t="repair_kit_item"

  "buildByPlayer:eid"{
  }

  "dependsOnBuildingEid:eid"{
  }

  "additiveBuildings:array"{
    "item:object"{
      template:t="rally_point_respawn_base+respawnChooser+respVehicle+vehicle_resp_soft_ground_collision+shred_outside_battle_area"
      tm:m=[[1.0, 0.0, 0.0] [0.0, 1.0, 0.0] [0.0, 0.0, 1.0] [8.0, 1.6, 0.2]]
    }

    "item:object"{
      template:t="rally_point_respawn_base+respawnChooser+respTeam1+resupply_zone+shred_outside_battle_area"
      tm:m=[[1.0, 0.0, 0.0] [0.0, 1.0, 0.0] [0.0, 0.0, 1.0] [5.5, 1.6, -0.2]]
    }

    "item:object"{
      template:t="rally_point_respawn_base+respawnChooser+respMotorcycle+vehicle_resp_soft_ground_collision+shred_outside_battle_area"
      tm:m=[[1.0, 0.0, 0.0] [0.0, 1.0, 0.0] [0.0, 0.0, 1.0] [3.0, 1.2, -0.2]]
    }
  }
}