add texture func
This commit is contained in:
parent
e860423821
commit
5e3713d14b
12
MANUAL.md
12
MANUAL.md
|
@ -30,6 +30,7 @@ Uranium Template originally formed during the creation of a currently unreleased
|
|||
- [`ActorFrame`](#actorframe)
|
||||
- [`ActorScroller`](#actorscroller)
|
||||
- [`BitmapText`](#bitmaptext)
|
||||
- [Textures](#textures)
|
||||
- [Shaders](#shaders)
|
||||
- [Callback usage](#callback-usage)
|
||||
- [Default callbacks](#default-callbacks)
|
||||
|
@ -340,6 +341,17 @@ However, providing custom fonts is a bit tedious due to a [vanilla bug](https://
|
|||
local text = BitmapText('../src/_inter v 22px.ini', 'test')
|
||||
```
|
||||
|
||||
#### Textures
|
||||
|
||||
For convinience, `Texture` is a function that will give you a `RageTexture` from a filename without the actor. Equivalent to:
|
||||
|
||||
```lua
|
||||
local sprite = Sprite('filename.png')
|
||||
sprite:hidden(1)
|
||||
local texture = sprite:GetTexture()
|
||||
return texture
|
||||
```
|
||||
|
||||
### Shaders
|
||||
|
||||
Shaders cannot be manually defined on actors [due to a technical limitation](https://discord.com/channels/227650173256466432/666629297544495124/1022119161415077909); plus, it wouldn't make much sense to integrate them in the same way that NotITG integrates shaders with the current XML behavior. In order to give an actor a shader, you need to define them seperately:
|
||||
|
|
2
template
2
template
|
@ -1 +1 @@
|
|||
Subproject commit 44bf4528df950d6cb93e361e7426b7e0d7548c84
|
||||
Subproject commit f4e8c1df7ca44eff65662d636fcb1ddb74254121
|
Loading…
Reference in New Issue