Search found 4 matches

by InsomniaNY
Mon Aug 11, 2014 9:03 pm
Forum: Libraries and Tools
Topic: Löve "Light vs. Shadow" Engine [0.4.3]
Replies: 117
Views: 122065

Re: Löve "Light vs. Shadow" Engine [0.4.3]

So I got it working, though I'm not exactly show why it works this way. Here's what I had to do to get it to work: lightMouse.setPosition(p.x, p.y) mouseP = {love.mouse.getPosition()} angleMouse_toPlayer = math.atan2(mouseP[1] - p.x, mouseP[2] - p.y) lightMouse.setDirection(angleMouse_toPlayer + ma...
by InsomniaNY
Sun Aug 10, 2014 9:45 pm
Forum: Libraries and Tools
Topic: Löve "Light vs. Shadow" Engine [0.4.3]
Replies: 117
Views: 122065

Re: Löve "Light vs. Shadow" Engine [0.4.3]

So I got it working, though I'm not exactly show why it works this way. Here's what I had to do to get it to work: lightMouse.setPosition(p.x, p.y) mouseP = {love.mouse.getPosition()} angleMouse_toPlayer = math.atan2(mouseP[1] - p.x, mouseP[2] - p.y) lightMouse.setDirection(angleMouse_toPlayer + mat...
by InsomniaNY
Sun Aug 10, 2014 4:10 pm
Forum: Libraries and Tools
Topic: Löve "Light vs. Shadow" Engine [0.4.3]
Replies: 117
Views: 122065

Re: Löve "Light vs. Shadow" Engine [0.4.3]

now im going to assume you lock the camera to render over the player at all times, and that the player is centerd on the screen at 400,300 assume that the torch light is stored under a variable [torch]. now to make the light point at the mouse we simply do : local mouseP = {love.mouse.getPosition()...
by InsomniaNY
Sat Aug 09, 2014 9:04 pm
Forum: Libraries and Tools
Topic: Löve "Light vs. Shadow" Engine [0.4.3]
Replies: 117
Views: 122065

Re: Löve "Light vs. Shadow" Engine [0.4.3]

First off, this is awesome! I'm new to Love2D, so I apologize if this is a noob question, but I didn't see it addressed... Is there a way to have a directional light point toward the mouse? I don't mean the position of the light, but rather the direction of an angled light - for example, if I wanted...