GML Trouble

Posted by Siert on Oct. 29, 2006, 4:35 p.m.

Okay, to start this out, I was at target and I saw one of those Idog things:

I was thinking, "OMG! That is so funny! Who would ever want one of those! Oh, it is a little dancing dog that listens to your music!" So then I poked around at it, and the left ear came of! OMFG! Then I went to hide it along with other crap, and I saw this:

Then I couldn't stop laughing and just hid the dog and left.


Okay, for the part I care about.

External Resources

Okay, I need some help, I used this line of code:

tex = background_add('Texture Maps/Light',false,false,true)

It works, without any errors, but the background it gives is just white.

I need help, here is the gm6 file if anyone wants to fiddle.

Comments

smaksak 18 years, 1 month ago

change these two lines

Quote:
shad_tex = background_add('Texture Maps/Ball',false,true,true)

tex = background_add('Texture Maps/Light',false,false,true)
to

shad_tex = background_get_texture(background_add('Texture Maps/Ball.bmp',false,true,true))
tex = background_get_texture(background_add('Texture Maps/Light.jpg',false,false,true))

Because you need to make the background to a texture (using background_get_texture) and you need to input the file extension when getting external files =)

DSG 18 years, 1 month ago

hmm i never do that… spaces around the =, lime x = 5 i always do x=5 i didnt know the other worked… hmmm

marbs 18 years, 1 month ago

I always do it with spaces around the = like "x = 5". I just always have.

noshenim 18 years, 1 month ago

I think spaces look messy and waste line width…

Siert 18 years, 1 month ago

I just use the spaces with the = because it spreads it out more and it is easier to read when the script has lots of words like this one.

And thanks smaksak.

NeutralReiddHotel 18 years, 1 month ago

Yeah, especially when they're words. It's just easier to read.

Siert 18 years, 1 month ago

Well, I now use external resources and my file size, (compressed) is still 14mb (300kb less), but it has so much faster loading time.

Alert Games 18 years, 1 month ago

Example of my code:

if (this = 2) or (that > 2) {
  if (this+that = 5) then
  show_message("fu")
  else
  this += 1
}

Also, my sister has an iDog and thinks it's cool >_> iDog (and fish) are failures.

Nighthawk 18 years, 1 month ago

I don't even have an iPod, so I'd have mo use for one anyway.

Amarin 18 years, 1 month ago

My sister has an iDog… She never uses it, thank God.