Skip to content

Commit

Permalink
allow passing arguments through drawfunctions
Browse files Browse the repository at this point in the history
  • Loading branch information
oatmealine committed Oct 17, 2022
1 parent 1086c87 commit b86c942
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
17 changes: 17 additions & 0 deletions MANUAL.md
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,23 @@ end

**Nested AFs are supported.** As with all complicated things in this template, check out the [`ActorFrame` example](#simple-actorframe-setup) for a simple working setup.

An additional extra feature Uranium Template adds to assist with rendering multiple instances is the ability to pass in arguments through `Draw()`:

```lua
setDrawFunction(af, function(x, y)
quad:xy(x, y)
quad:Draw()
end)

function uranium.update()
for x = 0, 3 do
for y = 0, 3 do
af:Draw(x, y)
end
end
end
```

#### `ActorScroller`

`ActorFrame` already has an extremely, _extremely_ complicated setup powering it in the back-end; and `ActorScroller` is way too niche for me to give it the same treatment. Sorry!
Expand Down
2 changes: 1 addition & 1 deletion template
Submodule template updated from 9681b0 to 99f8ab

0 comments on commit b86c942

Please sign in to comment.