Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help,
read this .
PGUp
Party member
Posts: 105 Joined: Fri Apr 21, 2017 9:17 am
Post
by PGUp » Sun Aug 04, 2019 10:27 am
Code: Select all
function love.load(arg)
for i,v in pairs(arg) do
print(v)
end
end
I ran the .love file with the following command:
the output of the print function is not showing the argument i passed with the command line
-
Konikoko
Prole
Posts: 5 Joined: Sat Aug 03, 2019 3:14 pm
Post
by Konikoko » Sun Aug 04, 2019 3:41 pm
I tried the following command in my cmd:
Code: Select all
"C:\Program Files\LOVE\love.exe" "tester" a b
and it worked for me.
I put the main.lua in a folder called tester with the following code:
Code: Select all
function love.load(arg)
for i,v in pairs(arg) do
print(v)
end
end
function love.update(dt)
end
function love.draw()
end
And I also wrote a conf.lua:
Code: Select all
function love.conf(t)
t.console = true
end
pgimeno
Party member
Posts: 3656 Joined: Sun Oct 18, 2015 2:58 pm
Post
by pgimeno » Sun Aug 04, 2019 9:59 pm
My guess: that calling the file, so that the executable to run is determined by extension, is not passing the additional parameters to said executable.
Try checking if there is any mechanism in your OS to solve that, or call the executable yourself as Konikoko suggests.
Users browsing this forum: Bing [Bot] and 6 guests