Team Spartan Cookies & Milk Forums
  • Issue Tracker
  • Donations
  • Search
  • Member List
  • Help

Register

Team Spartan Cookies & Milk Forums Garry's Mod Starfall v
« Previous 1 2 3 4 5 6 … 18 Next »
UV issue in drawTexturedRect
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Linear Mode
UV issue in drawTexturedRect
12-07-2020, 02:04 PM, (This post was last modified: 12-07-2020, 02:09 PM by Tomeno. Edited 5 times in total.)
#11
Tomeno Offline
TSCM Member
***
Posts: 10
Threads: 3
Joined: Jul 2020
RE: UV issue in drawTexturedRect
Found a material that doesn't seem to work with Material();
--@highres true
local mat = Material("spacebuild/hazard2.vmt")
local tex = render.getTextureID("spacebuild/hazard2.vmt")
hook( "render", "render", function()
render.clear()
render.setMaterial(mat)
render.setColor(255, 255, 255, 255)
render.drawTexturedRect(0, 0, 512, 512)
render.setTexture(tex)
render.setColor(255, 255, 255, 255)
render.drawTexturedRect(512, 0, 512, 512)
end)
If you remove the .vmt from the end of the material path for "tex", it'll stop drawing as well. The presence of an extension has no effect on "mat".

EDIT: I thought I tried it, but using setTexture with "mat" makes it draw now... Must be my fault then.
EDIT 2: Oh. It only works in a HUD, and it has lighting applied. Doesn't work on a screen.
Find
Reply
« Next Oldest | Next Newest »


Messages In This Thread
UV issue in drawTexturedRect - by Tomeno - 11-07-2020, 11:03 PM
RE: UV issue in drawTexturedRect - by Person8880 - 12-07-2020, 09:53 AM
RE: UV issue in drawTexturedRect - by Tomeno - 12-07-2020, 10:13 AM
RE: UV issue in drawTexturedRect - by Person8880 - 12-07-2020, 10:39 AM
RE: UV issue in drawTexturedRect - by Tomeno - 12-07-2020, 10:43 AM
RE: UV issue in drawTexturedRect - by Person8880 - 12-07-2020, 10:48 AM
RE: UV issue in drawTexturedRect - by Tomeno - 12-07-2020, 10:53 AM
RE: UV issue in drawTexturedRect - by Person8880 - 12-07-2020, 11:08 AM
RE: UV issue in drawTexturedRect - by Tomeno - 12-07-2020, 01:22 PM
RE: UV issue in drawTexturedRect - by Person8880 - 12-07-2020, 01:35 PM
RE: UV issue in drawTexturedRect - by Tomeno - 12-07-2020, 02:04 PM
RE: UV issue in drawTexturedRect - by Person8880 - 12-07-2020, 02:19 PM
RE: UV issue in drawTexturedRect - by Tomeno - 12-07-2020, 02:48 PM
RE: UV issue in drawTexturedRect - by Person8880 - 12-07-2020, 02:51 PM

  • View a Printable Version
Forum Jump:


Users browsing this thread: 1 Guest(s)
Contact UsTeam Spartan Cookies & MilkReturn to TopLite (Archive) ModeMark all forums readRSS Syndication

Powered By MyBB, © 2002-2026 MyBB Group.