Newer
Older
DungeonShooting / DungeonShooting_Godot / src / game / ui / mapEditorProject / RoomButtonCell.cs
@小李xl 小李xl on 10 Aug 2023 584 bytes 创建房间标记, 开发中
  1. using Godot;
  2.  
  3. namespace UI.MapEditorProject;
  4.  
  5. public class RoomButtonCell : UiCell<MapEditorProject.RoomButton, DungeonRoomSplit>
  6. {
  7. public override void OnSetData(DungeonRoomSplit data)
  8. {
  9. CellNode.L_RoomName.Instance.Text = data.RoomInfo.RoomName;
  10. CellNode.L_RoomType.Instance.Text = DungeonManager.DungeonRoomTypeToDescribeString(data.RoomInfo.RoomType);
  11. CellNode.Instance.TooltipText = "路径: " + data.RoomPath;
  12. }
  13.  
  14. public override void OnDoubleClick()
  15. {
  16. //打开房间编辑器
  17. CellNode.UiPanel.SelectRoom(Data);
  18. }
  19. }