C++ helpen out blitz.
Moderator: Coders of Rage
- JS Lemming
- Game Developer
- Posts: 2383
- Joined: Fri May 21, 2004 4:09 pm
- Location: C:\CON\CON
C++ helpen out blitz.
I found something pretty neat just a few seconds ago while looking through mai old blitz folder.
You can write functions in C++ and compile them into .dll's. Which blitz will then recognize in it's IDE and stuff. Not that I'm going to use blitz or anything, but i bet Arce will think it's pretty koo.
You can write functions in C++ and compile them into .dll's. Which blitz will then recognize in it's IDE and stuff. Not that I'm going to use blitz or anything, but i bet Arce will think it's pretty koo.
Small girl at the harbor wrote:Look Brandon, that crab's got ham!
- Falco Girgis
- Elysian Shadows Team
- Posts: 10294
- Joined: Thu May 20, 2004 2:04 pm
- Current Project: Elysian Shadows
- Favorite Gaming Platforms: Dreamcast, SNES, NES
- Programming Language of Choice: C/++
- Location: Studio Vorbis, AL
- Contact:
- JS Lemming
- Game Developer
- Posts: 2383
- Joined: Fri May 21, 2004 4:09 pm
- Location: C:\CON\CON
C++ helpen out blitz.
Arce, you know when you type a key word command like .... Abs() for example... and it turns yellow like.
Well, you can make your own functions that act just like that. Like they were built in all along.
AND c++ is more powerful and FASTER!!!!!! Oh the pointers!
They should have named pointers something cooler.
EDIT - hehe. i just noticed i didn't answer your question. A: you would use one of the many different ways to iterate throuh classes in c++ instead of types yo.
Well, you can make your own functions that act just like that. Like they were built in all along.
AND c++ is more powerful and FASTER!!!!!! Oh the pointers!
They should have named pointers something cooler.
EDIT - hehe. i just noticed i didn't answer your question. A: you would use one of the many different ways to iterate throuh classes in c++ instead of types yo.
Last edited by JS Lemming on Sat Oct 16, 2004 6:11 pm, edited 2 times in total.
Small girl at the harbor wrote:Look Brandon, that crab's got ham!
- Falco Girgis
- Elysian Shadows Team
- Posts: 10294
- Joined: Thu May 20, 2004 2:04 pm
- Current Project: Elysian Shadows
- Favorite Gaming Platforms: Dreamcast, SNES, NES
- Programming Language of Choice: C/++
- Location: Studio Vorbis, AL
- Contact:
- JS Lemming
- Game Developer
- Posts: 2383
- Joined: Fri May 21, 2004 4:09 pm
- Location: C:\CON\CON
No not at all. What does types have to do with a function. All you have to do is make a c++ function like so:Arce wrote:So if I wanted one, lets say, collision function in C++, I'd have to redo the whole program so it doesn't have types? o.o
Code: Select all
//Returns true if the two rectangles are overlapping
bool RectsOverlap(int x1,int y1,int width1,int height1,int x2,int y2,int width2,int height2) {
if((x1+width1 > x2) && (x1 < x2+width2)) {
if((y1+height1 > y2) && (y1 < y2+height2)) {
return true;
}
}
return false;
}
Code: Select all
if RectsOverlap(dude\x,dude\y,32,64,bullet\x,bullet\y,2,2)
dude\life = dude\life - 1
endif
PS. that collision function was just an example!!!
Remember when i said:Super Sonic wrote:Yeah, JSL, are you talking about referring to types from C++ as if they were just classes, declaring the classes in C++ then somehow using them in blitz, or having the blitz and C++ classes/types be completely noncompatable with each other?
Well, i must have been half asleep/dead. I meant to say that you could just have a loop and iterate through your types while passing thier data into the function, makeing classes useless. Sorry.A: you would use one of the many different ways to iterate throuh classes in c++ instead of types yo.
Small girl at the harbor wrote:Look Brandon, that crab's got ham!
- Falco Girgis
- Elysian Shadows Team
- Posts: 10294
- Joined: Thu May 20, 2004 2:04 pm
- Current Project: Elysian Shadows
- Favorite Gaming Platforms: Dreamcast, SNES, NES
- Programming Language of Choice: C/++
- Location: Studio Vorbis, AL
- Contact:
- Don Pwnious
- Chaos Rift Devotee
- Posts: 833
- Joined: Tue Jun 15, 2004 5:32 pm
- Location: on the streets wit my j23
- Contact:
- JS Lemming
- Game Developer
- Posts: 2383
- Joined: Fri May 21, 2004 4:09 pm
- Location: C:\CON\CON
A memory bank is just that, a block of memory set aside for your use. What's so great about it? The fact that it is FAST. Fast as a mug. It's perfect for compression functions and stuff.
Gadgets: You might have noticed that blitz can also make windows like programs (note: VmuGx). Gadgets are things like buttons and scroll bars and menus and everything.
A progress bar is a gadget that can be used to inform the user how muchan operation has been completed. Example: A load bar.
Gadgets: You might have noticed that blitz can also make windows like programs (note: VmuGx). Gadgets are things like buttons and scroll bars and menus and everything.
A progress bar is a gadget that can be used to inform the user how muchan operation has been completed. Example: A load bar.
Small girl at the harbor wrote:Look Brandon, that crab's got ham!
- Falco Girgis
- Elysian Shadows Team
- Posts: 10294
- Joined: Thu May 20, 2004 2:04 pm
- Current Project: Elysian Shadows
- Favorite Gaming Platforms: Dreamcast, SNES, NES
- Programming Language of Choice: C/++
- Location: Studio Vorbis, AL
- Contact:
- JS Lemming
- Game Developer
- Posts: 2383
- Joined: Fri May 21, 2004 4:09 pm
- Location: C:\CON\CON