Content Patcher

Content Patcher

378k Downloads

[Content Patcher] Rectangle Tokens

spacechase0 opened this issue ยท 3 comments

commented

Allow tokens to supply values for Rectangles. This would allow simplifying some mods with dynamic tokens, and allow for things like Json Assets coordinate tokens (for applying textures to JA objects).

commented

@spacechase0 To clarify, are you suggesting a token which returns a Rectangle instance:

"FromArea": "{{SourceArea}}"

Or letting you specify rectangle arguments using tokens:

"FromArea": { "X": "{{SourceX}}", "Y": "{{SourceY}}", "Width": 16, "Height": 16 }
commented

The first would break a core assumption in the Content Patcher design and involve a major rewrite; the second is simple to implement. So let's go for the second one. ;)

commented

Either would work for me (so long as it is possible from the perspective of a mod providing tokens). I'm not sure what would be preferred from a content pack creator's perspective.