Skip to content

Commit

Permalink
fix(poh): cleanup and some docs added
Browse files Browse the repository at this point in the history
- cleaned up some unused or redundant methods
- documented about half of the file
This can already be used I guess.
  • Loading branch information
Torwent committed Feb 4, 2024
1 parent c6387d0 commit 45d9990
Show file tree
Hide file tree
Showing 2 changed files with 256 additions and 77 deletions.
25 changes: 24 additions & 1 deletion optional/handlers/houseobjects.simba
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ type
RoomOffset: TPoint;
end;

procedure TRoomObject.Setup(upText: TStringArray; shape: Vector3; roomOffset: TPoint);
procedure TRoomObject.Init(upText: TStringArray; shape: Vector3; roomOffset: TPoint);
begin
Self := [];
Self.Shape := shape;
Expand All @@ -25,6 +25,29 @@ begin
Self.Finder.Grow := 4;
end;

procedure TRoomObject.Setup(obj: ERSRoomObject); overload;
begin
case obj of
ERSRoomObject.POOL:
begin
Self.Init(['pool'], [1.5, 1.5, 6], [4,4]);
Self.Finder.Colors := [CTS2(11514040, 19, 0.10, 0.13)];
end;

ERSRoomObject.FAIRY_TREE:
begin
Self.Init(['Fairy', 'Tree'], [1.5, 1.5, 6], [16,16]);
Self.Finder.Colors := [CTS2(7307158, 15, 0.48, 0.69)];
end;

ERSRoomObject.JEWELLERY_BOX:
begin
Self.Init(['Jewellery', 'Box'], [2, 2, 6], [4,4]);
Self.Finder.Colors := [CTS2(1287353, 17, 0.02, 0.72), CTS2(530791, 8, 0.24, 2.28)];
end;
end;
end;

procedure TRoomObject.AddCoordinates(coordinates: TPointArray);
begin
Self.Coordinates += coordinates;
Expand Down
Loading

0 comments on commit 45d9990

Please sign in to comment.