Search found 18 matches

by ZodaInk
Tue Jan 26, 2016 7:12 pm
Forum: Support and Development
Topic: [Solved] Math.random creates a weird pattern
Replies: 5
Views: 3021

[Solved] Math.random creates a weird pattern

I have no idea how this happens or even if this is a problem with Löve. While the pattern is almost random, it is not the kind of random I want. Tell me if it works fine for you or if you find something in the code that is wrong. The .love file creates a grid and every tile in that grid has a 90%(is...
by ZodaInk
Fri Nov 13, 2015 11:27 am
Forum: Support and Development
Topic: [Beginner] [SOLVED] getting attempt to index global er
Replies: 11
Views: 4652

Re: [Beginner] [Thranduil UI] getting attempt to index globa

I'm on Xubuntu and dots works. I'm on Ubunutu 14.04 and Elementary Os, dots doesn't work on either. Maybe there's no need to comment out self.joysticks = love.joystick.getJoysticks() . Just set t.modules.joystick = true in conf.lua. I didn't look at the conf.lua... That was stupid of me. So, follow...
by ZodaInk
Fri Nov 13, 2015 11:13 am
Forum: Support and Development
Topic: [Beginner] [SOLVED] getting attempt to index global er
Replies: 11
Views: 4652

Re: [Beginner] [Thranduil UI] getting attempt to index globa

I still had problems with Thranduil using "." to separate folders, but after manually editing all "." with "/" I found the problem. Well, there are two problems, one is that you never initialize the "button" variable. At least not before you try to use it (but...
by ZodaInk
Fri Nov 13, 2015 10:11 am
Forum: Support and Development
Topic: [Beginner] [SOLVED] getting attempt to index global er
Replies: 11
Views: 4652

Re: [Beginner] [Thranduil UI] getting attempt to index globa

Why do you separate folders with "."? require "libs.hump.gamestate" This does not work (on ubuntu/linux at least). Instead use "/" like this: require "libs/hump/gamestate" It's hard to help you since I can't even open the game to check out your error, and it's...
by ZodaInk
Mon Nov 02, 2015 7:03 pm
Forum: Support and Development
Topic: init script?
Replies: 10
Views: 6420

Re: init script?

is there a function that splits the string between the nth char? and supports negative values? Yes, no. You can split something by the nth character with string.sub(). You can make a simple function that supports negative values. function splitTheNthChar(str, i) if i > 0 then return string.sub(str,...
by ZodaInk
Wed Jun 24, 2015 3:04 pm
Forum: Support and Development
Topic: Changing lines and color on strings fails
Replies: 3
Views: 1708

Re: Changing lines and color on strings fails

v in the loop in the draw.string function is never equal to "\n" This doesn't matter, because it should still detect an empty string (v == "\n" or v == ""), scan.string is the only function that needs to detect "\n". So the scan.string fail somewhere: if you ...
by ZodaInk
Wed Jun 24, 2015 1:54 am
Forum: Support and Development
Topic: Changing lines and color on strings fails
Replies: 3
Views: 1708

Changing lines and color on strings fails

I've made my own string formatting code which is failing me for some unknown reason. What I have achieved is a function that replaces certain syntax with strings (character names for example). That same function and syntax should also be able to change the color of the text, which it can, but is for...
by ZodaInk
Fri Jan 09, 2015 12:15 am
Forum: Support and Development
Topic: Relative filepath for love.image.newImageData
Replies: 2
Views: 2527

Relative filepath for love.image.newImageData

After many attempts and just as many failures. The game just does not want to load images outside the .love file. It seems that parent folders doesn't work for love.graphics.newImage, which would suck in this case. This is what I've been trying: character.display[charname].texture.head = love.graphi...