Search found 1181 matches

by darkfrei
Wed Jan 03, 2024 8:18 am
Forum: Support and Development
Topic: How to path around blocked tiles with jumper?
Replies: 12
Views: 84622

Re: How to path around blocked tiles with jumper?

Brah wrote: Wed Jan 03, 2024 8:02 am I think I have an older version of jumper because I don't have THETASTAR and my getPath coordinates are X,Y...
Do you have any stuff on weighted grids and movement costs?
Dijkstra?
by darkfrei
Tue Dec 19, 2023 8:01 pm
Forum: Libraries and Tools
Topic: Parabola functions in Lua
Replies: 11
Views: 88335

Re: Parabola functions in Lua

Small example to calculate p h k form of parabola to a b c form with example local p = -2 -- vertical distance to focus (negative as direction) local h = 2 -- horizontal shift local k = 8 -- vertical shift print ('h:'..h, 'p:'..p, 'k:'..k) local a = 1/(4*p) local b = -2*a*h local c = a*h^2+k print (...
by darkfrei
Sun Dec 17, 2023 7:47 pm
Forum: Support and Development
Topic: Justified text displaying one character at a time
Replies: 13
Views: 64537

Re: Justified text displaying one character at a time

Thanks RNavega! It's awesome! Now I need to understand it and get how to do the DIY-justification.
by darkfrei
Sun Dec 17, 2023 9:21 am
Forum: Support and Development
Topic: Justified text displaying one character at a time
Replies: 13
Views: 64537

Re: Justified text displaying one character at a time

Just for academic interest, instead of using black rectangles, you can totally mask with transparency using a shader: you have 2 float uniforms, both in screen-space, which represent 2 "rays" that divide the screen: one being a horizontal ray that moves from top to bottom and above which ...
by darkfrei
Thu Dec 14, 2023 7:49 pm
Forum: Support and Development
Topic: Displaying (or Drawing) Coordinates
Replies: 3
Views: 18411

Re: Displaying (or Drawing) Coordinates

cords.coordinates not defined;
Also

Code: Select all

local k = shiftPressed and 2 or 1
player.x = player.x + dx*k*player.speed
player.y = player.y + dy*k*player.speed
by darkfrei
Thu Dec 14, 2023 11:18 am
Forum: Support and Development
Topic: Love tutorial about input
Replies: 3
Views: 21997

Re: Love tutorial about input

https://love2d.org/wiki/KeyConstant

Code: Select all

love.keyboard.isDown( "space" ) then
by darkfrei
Tue Dec 12, 2023 11:15 am
Forum: Support and Development
Topic: Justified text displaying one character at a time
Replies: 13
Views: 64537

Re: Justified text displaying one character at a time

The fake and self made justification: blackString = [[I'm trying to implement the effect you see in many games where text is printed a character at a time. (See the original Dragon Quest for an example.) On its own this is easy: all one needs to do is keep a counter then use string.sub and utf8.offs...
by darkfrei
Tue Dec 12, 2023 8:45 am
Forum: Support and Development
Topic: Justified text displaying one character at a time
Replies: 13
Views: 64537

Re: Justified text displaying one character at a time

Not justification, but you cannot see it: blackString = [[I'm trying to implement the effect you see in many games where text is printed a character at a time. (See the original Dragon Quest for an example.) On its own this is easy: all one needs to do is keep a counter then use string.sub and utf8...
by darkfrei
Mon Dec 11, 2023 4:28 pm
Forum: Support and Development
Topic: Justified text displaying one character at a time
Replies: 13
Views: 64537

Re: Justified text displaying one character at a time

I don't like how the line "about it" looks out:
2023-12-11T17_28_07-Untitled.png
2023-12-11T17_28_07-Untitled.png (21.1 KiB) Viewed 49473 times