Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / set image colorkey

Author
Message
Mr X
18
Years of Service
User Offline
Joined: 25th Sep 2005
Location: Universe, milkyway, sol-system, Earth...
Posted: 22nd Apr 2006 13:22 Edited at: 22nd Apr 2006 13:23
Hi all.

Im having trubble with the "set image colorkey" command. I tried with
and then
, but you can still see the black parts of the images (or sprites) that I use in my game for ships. What am I doing wrong? Is it the command, or is it something else?

Code:
Daemon
18
Years of Service
User Offline
Joined: 16th Dec 2005
Location: Everywhere
Posted: 22nd Apr 2006 18:52 Edited at: 22nd Apr 2006 18:54
I don't know why in you code you have

It should be set image colorkey 0,0,0

Since you said you tried this, then the problem is probably with your image.

Load the image into paint and then click on it with the dropper tool thing (it says "Pick Color" when you hold your mouse over the tool) on a black part. This should make the color you are using be the color of the black part. Then go to the "colors" menu, "edit colors...", and then click "define custom colors >>". It will show the rgb values for that black part of the image you clicked. You might find that your black parts are not exactly 0,0,0. Hopefully this helps you get set image colorkey working, as I don't think it is the code which is causing problems.

I could help more if you posted your image.

Insanity is just a state of mind
Mr X
18
Years of Service
User Offline
Joined: 25th Sep 2005
Location: Universe, milkyway, sol-system, Earth...
Posted: 22nd Apr 2006 19:05
It works now, when I took a look at the color in paint, I discovered that one number was at 160 instead of 0.

The "set image colorkey rgb(0,0,0),rgb(0,0,0),rgb(0,0,0)" was because I tried the one you suggested, and then I tested something different.

Thanks for the help.

Login to post a reply

Server time is: 2024-09-24 21:40:09
Your offset time is: 2024-09-24 21:40:09