This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
stefan's profile picture

GPS host startup script not working

Started by stefan, 20 January 2013 - 02:11 AM
stefan #1
Posted 20 January 2013 - 03:11 AM
Hi all

I've read the other posts on this forum about people having similar issues with the gps host startup script. The proposed solutions however, aren't working for me for some reason.

I'm using the current SolitaryCraft build, which has Computercraft v1.481

My startup script contains:

shell.run("gps", "host", -334, 252, 216)

After I reboot, I'm getting:

=======================
CraftOS 1.4
Usages:
gps host
gps host <x> <y> <z>
gps locate
>
=======================

So it seems to me that shell.run isn't properly passing the arguments to the gps program.

I've also tried all the other variations I've found in posts on this forum, to no avail. I always end up with the same result.

Can anyone help out?

Cheers
Cloudy #2
Posted 20 January 2013 - 03:13 AM
Pass the arguments as strings.
TheOddByte #3
Posted 20 January 2013 - 03:14 AM
Umm…
I think you have to do the " " like this

shell.run("gps", "host", "-334", "252", "216")
theoriginalbit #4
Posted 20 January 2013 - 03:16 AM
Umm…
I think you have to do the " " like this

[color=#282828][font=helvetica, arial, sans-serif]shell.run("gps", "host", "-334", "252", "216")[/font][/color]
Without all the color and font tags of course it would look something a little more like this

shell.run( "gps", "host", "-334", "252", "216" )