Jump to content




[whats wrong] <<explains


  • You cannot reply to this topic
17 replies to this topic

#1 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 11 March 2013 - 02:32 PM

i am making (yes, ANOTHER) an os and i am COMPLETELY stuck on the desktop.

i painted a pic in paint. named it .desktop

then did this.

desk = paintutils.loadImage(".desktop")
paintutils.drawImage(desk,1,1)
i get error;

paintutils:92:attempt to get length of nil

i uninstalled and reinstalled cc

halp?

#2 Sammich Lord

    IRC Addict

  • Members
  • 1,212 posts
  • LocationThe Sammich Kingdom

Posted 11 March 2013 - 02:33 PM

Did you check that .desktop is in the same directory that the script you are running is? You should also use exact paths.

#3 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 11 March 2013 - 02:35 PM

it is;


whats an exact path?

#4 Sammich Lord

    IRC Addict

  • Members
  • 1,212 posts
  • LocationThe Sammich Kingdom

Posted 11 March 2013 - 02:37 PM

For instance: "/.desktop" instead of ".desktop". This insures it accesses the file from that directory instead of the directory it was ran from.

#5 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 11 March 2013 - 02:38 PM

still same error

#6 Sammich Lord

    IRC Addict

  • Members
  • 1,212 posts
  • LocationThe Sammich Kingdom

Posted 11 March 2013 - 02:44 PM

Just looked at the API. It is trying to get the length of a table that does not exist meaning that it could not save the image to the file.
Mind giving the contents of ".desktop"?

#7 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 11 March 2013 - 02:45 PM

ok

#8 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 11 March 2013 - 02:47 PM

http://pastebin.com/rtYSpVym

#9 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 11 March 2013 - 02:49 PM

i tried it in a diff. program,

no cigar

#10 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 11 March 2013 - 02:57 PM

abandonment :(

#11 remiX

  • Members
  • 2,076 posts
  • LocationSouth Africa

Posted 11 March 2013 - 05:45 PM

Where EXACTLY did you put the .desktop file?

#12 Dlcruz129

    What's a Lua?

  • Members
  • 1,423 posts

Posted 11 March 2013 - 06:09 PM

You definitely have the two files in different directories.

#13 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 12 March 2013 - 11:24 AM

its in cd/disk
and the drawing file is in cd/disk

#14 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 12 March 2013 - 11:32 AM

i really need this :(

#15 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 12 March 2013 - 11:41 AM

i got it

i used npaintpro instead of paint

#16 LuaEclipser

  • Banned
  • 220 posts
  • LocationCleveland, Ohio

Posted 12 March 2013 - 11:56 AM

and cant use cd disk

#17 SuicidalSTDz

    Permutator of Strings

  • Members
  • 1,308 posts
  • LocationPennsylvania

Posted 12 March 2013 - 02:07 PM

View PostLuaEclipser, on 12 March 2013 - 11:24 AM, said:

its in cd/disk
and the drawing file is in cd/disk

View PostLuaEclipser, on 12 March 2013 - 11:32 AM, said:

i really need this :(

View PostLuaEclipser, on 12 March 2013 - 11:41 AM, said:

i got it

i used npaintpro instead of paint

View PostLuaEclipser, on 12 March 2013 - 11:56 AM, said:

and cant use cd disk
Instead of creating a new post every 5 minutes, why don't you use that handy 'Edit' button near the bottom of your post. <_<

#18 remiX

  • Members
  • 2,076 posts
  • LocationSouth Africa

Posted 12 March 2013 - 05:39 PM

If it's in DISK then you need
desk = paintutils.loadImage(".desktop")
to be
desk = paintutils.loadImage("disk/.desktop")






2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users