Arcade InterfaceTexturedRect

Forum Archive - from http://theuniversal.net
LegoGirl
Posts: 34
Joined: Tue Jan 27, 2004 1:27 pm

Post by LegoGirl »

Well, I can work around it. I thought negative coordinates were OK tho.

Personally I'd remove it (unless it's there because the game uses it), people can center their own stuff. :roll:
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post by Mit »

ok, got rid of the -1 stuff now :].

um, re the texturedrect layers.. i made a bit of an inconsistency there with the layer in the InterfaceTexturedRect and the one defined InterfaceCreateNewTexturedOverlay. i.e. The layer should probably be defined either per rect and per overlay.

I could either (1) get rid of the layer param in TexturedRect, (2) get rid of the layer param in createnewtexturedoverlay or (3) implement them both and have the texturedrec layer override the overlay one if it is specified.

(1) is the easiest and neatest to put in, so that all rects on an overlay are on the same layer - would that be a nuisance for you?
(2) i can do today but its not very neat - would prefer not to do that if (1) is bearable?
(3) would be a bit of a fudge really :)

p.s. Had a quick look at your stuff.. Is very very very nice :) :) :) :)
LegoGirl
Posts: 34
Joined: Tue Jan 27, 2004 1:27 pm

Post by LegoGirl »

(3) would be ideal (and is the closest to what it was using) but I can see how it could be a pig to do. (1) is definitely bearable, so I'd do that. I just need to be able to have a texture associated with more then one overlay.
p.s. Had a quick look at your stuff.. Is very very very nice
ta. The shooting's better now. The excessive number of stars made the bullets, smoke and explosions intermittent. :oops:
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post by Mit »

right.. I looked briefly at (3), didnt like it much :], then thought about leaving the params in and doing it later, but eventually Ive gone with (1) and removed the layer param from the textured draw functions. Does help keep the code neater internally, and reduces the rather long list of params to those functions a lil. Dont think having layers per overlay will be a massive limitation in general and is probably best to get it set now. Sorry if that means having to rejig ur stuff a bit.
There should be no problem using a single texture on multiple overlays.

Untested (as usual) til i get home..
http://gameislands.net/intpatch3feb04.zip
LegoGirl
Posts: 34
Joined: Tue Jan 27, 2004 1:27 pm

Post by LegoGirl »

I'm getting linker errors with InterfaceTexturedRect :(
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post by Mit »

i think i somehow managed not to include the modified version of the header in the zip :?

is http://gameislands.net/intpatch4Feb04.zip any better?
LegoGirl
Posts: 34
Joined: Tue Jan 27, 2004 1:27 pm

Post by LegoGirl »

Well, the link error's gone :)

But it doesn't display anything and gives a texture load error when I press the function key for my game (F3) :(
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post by Mit »

not so good then :). um, will have to check it properly after work... will try to get a fix posted here tonight
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post by Mit »

k, done.. i think it jus needed the standalone arcade.exe updating coz it was drawing the arcade machine backdrop over the top. Cant test your prog properly coz the dll needs rebuilding but i got invaders working ok after a rebuild.

http://i-lands.net/ArcadeSource2Feb04.zip is the latest version of everythin.
User avatar
Knoxjoey
Posts: 98
Joined: Tue Sep 30, 2003 8:52 pm
Location: Canada
Contact:

Post by Knoxjoey »

ta. The shooting's better now. The excessive number of stars made the bullets, smoke and explosions intermittent.
:o this wouldent happen too be a remake of Whoomph would it ??? :D (i havent had the internet for a while so if it has been said what it is i'm sorry :( )

p.s love the new banner on the site mit ^_^
LegoGirl
Posts: 34
Joined: Tue Jan 27, 2004 1:27 pm

Post by LegoGirl »

this wouldent happen too be a remake of Whoomph would it ???
Sorry, no it isn't. If Mit wants a version of Woomph it could be done.
k, done.. i think it jus needed the standalone arcade.exe updating coz it was drawing the arcade machine backdrop over the top. Cant test your prog properly coz the dll needs rebuilding but i got invaders working ok after a rebuild.
Excellent, that's fixed just about everything, ta.
Soooo, how might the colour stuff work then? :twisted:
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post by Mit »

I was thinking of saving an arcade version of woomph as a task for the summer when ive finished the galaxy and wanna take a break from the heavy stuff.... Course it'd need to be multiplayer and that would be .. um.. interesting.
Lego's thing is a better arcade game anyway :)

Colour stuff? ARGB 32 bit values, they should be modulated with any textures you're using. Unless it doesnt work, of course..
LegoGirl
Posts: 34
Joined: Tue Jan 27, 2004 1:27 pm

Post by LegoGirl »

Colour stuff? ARGB 32 bit values, they should be modulated with any textures you're using. Unless it doesnt work, of course..
Ooooooooo...Excellent! That's better then I could've hoped for. :D
I'll just make all my GFX white and select the colours at runtime. :twisted:
Lego's thing is a better arcade game anyway :)
:oops:
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post by Mit »

I was thinkin of making them BARG instead, i mean.. ya know.. jus for a laugh...

never know, it might catch on.
LegoGirl
Posts: 34
Joined: Tue Jan 27, 2004 1:27 pm

Post by LegoGirl »

a long time ago Mit wrote:Yeh, -1, -1 is used to denote an image that should be centered on the screen. Did i not mention that in the docs? ;]
and then Mit wrote:ok, got rid of the -1 stuff now :].
Erm..It seems to be back in :?
Did ya think you could sneek that back in without me noticing...eh? :twisted:
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post by Mit »

doh. *flog Mit for forgettin to check in the stuff he changed at work before rebuilding it at home... Will do a (last final final) build tonite..
User avatar
Mattizme
Posts: 615
Joined: Sat Oct 04, 2003 6:23 pm
Location: At work/school/home
Contact:

Post by Mattizme »

Sounds like this Arcade malarky is finally taking off - fancy helping out on the Pants Arcade Project, Lego? Please? :)

By the way, Mittie.. is there any chance of a default value for centreing? I know I'm just being lazy, but I can remember that with Invaders I had super smashing great fun trying to centre things, and it jus turned out to be a bit of a kludge. so, if poss (Even if it's jus -65536) could you put it in? :]
LegoGirl
Posts: 34
Joined: Tue Jan 27, 2004 1:27 pm

Post by LegoGirl »

This is how to center stuff. Just use this function instead of Mit's. You could even turn it into a macro.

Code: Select all

void InterfaceTexturedRectCentred(
    int nOverlay,
    int nX, int nY,
    int nWidth, int nHeight,
    int nColour, 
    float fU1, float fV1, float fU2, float fV2 )
{
    if( nX == -1 &&
        nY == -1 )
    {
        nX = (InterfaceGetWidth()/2) - (nWidth/2);
        nY = (InterfaceGetHeight()/2)- (nHeight/2);
    }
    InterfaceTexturedRect(
        nOverlay,
        nX, nY,
        nWidth, nHeight,
        nColour, 
        fU1, fV1, fU2, fV2 );
}
Mattizme wrote:Sounds like this Arcade malarky is finally taking off - fancy helping out on the Pants Arcade Project, Lego? Please?
I'm kinda enjoying doing my own random stuff right now. :twisted:
If you need a bit of help tho, just ask :)
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post by Mit »

LegoGirl
Posts: 34
Joined: Tue Jan 27, 2004 1:27 pm

Post by LegoGirl »

Mit wrote:fingers crossed..
That's all working now, ta. :D
Locked