News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests

Main Menu

my 100% Assembly game development

Started by LordAdef, May 01, 2017, 03:22:26 PM

Previous topic - Next topic

LordAdef

Back to the transparent topic.

The suggestions given made me do a lot o research. For those interested I found this nice tuto. He gives two methods, I was using the first. the second is Marinus´ one, but he does it with a bitblt trick, to avoid the setPixels:

http://www.winprog.org/tutorial/transparency.html

I ended up using TransparentBitBlt in the current version. It´s working nicely and without much effort. the bonus is that it can stretch images too.


v818a:
=>1 Traced 2 bugs with OllyDbg, and 1 bug related to logic. Those could possibly make win10 work properly now (I hope)
ps: when killed, enemies stop flying for now (on purpose, to adjust the code)

Hope it works now




Siekmanski

Creative coders use backward thinking techniques as a strategy.

HSE

Perfect now!  :t

You can see later (here for example) that no setPixel is used to draw.
Equations in Assembly: SmplMath


LordAdef

Quote from: HSE on February 23, 2018, 12:26:23 PM
Perfect now!  :t

You can see later (here for example) that no setPixel is used to draw.

Hi HSE, thanks I´ll check that code. I followed this link but actually didn´t studied the code.

daydreamer

it would be cool to make a martian game based on this:
https://en.wikipedia.org/wiki/Valles_Marineris
do you plan on make game Engine able to import bitmaps as maps, a low res version as tilemap,hires version as terrain texture?
my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

LordAdef

Quote from: daydreamer on March 04, 2018, 11:29:31 PM
it would be cool to make a martian game based on this:
https://en.wikipedia.org/wiki/Valles_Marineris
do you plan on make game Engine able to import bitmaps as maps, a low res version as tilemap,hires version as terrain texture?

Not in the current plan DayDreamer. It's not a tilemap engine.

The good news is I got professional guys (from India!) to work on the art for the game! A friend of mine is going to do sound Fx.

If I cannot find anyone, I will do the soundtrack myself, although I'd rather stay away from the music in this project.

Lonewolff

Doing great, man!  8)

Getting pretty close to trying my hand at a simple game, once I am up to a decent level with ASM.

LordAdef

#128
Cheers LoneWolf!


As a quick update, my first post here after it's been moved to Game deve Forum:

This project is in full development!
I'm not posting anything new only because I'm changing too many things for this next build. Mostly code stuff related.

However, to tease things a bit, I'd like to show you guys the concept draft for the player's plane (the current art is solely for development):



LordAdef

I've been setting my game loop timings with QueryPerformanceCount, frequency, sleep granularity with TimeBeginTime etc...


The good news is that without any serious optimization (and a lot can be gained), I'm currently achieving 4 milliseconds per frame on my machine (bitblting to a 1920/1080 window size). Since I'm targeting a game running at 60 FPS (about 17 msec), I've got lots of headroom! And no memory leaks.


Not that bad for a beginner, I guess... :icon_cool:

LordAdef

Guys,

This is a test version. I'm doing a bunch of changes and it's quite broken as of now. Would you running it for me? It's broken, all I want is to see how it behaves on your machines.

The console is my debbuger, if you press (the top number 8, not the one in the numpad), it will output the relevante data for my test: frame rate, sleep time, and FPS.

I appreciate the help.

jj2007

Stack overflow on Win7-64 :(------------ Debugger started --------------

.code

Win Main
WM==Create **********************
------- Create DC start -----------------

** width: 76  height: 48
** width: 25  height: 48
** width: 72  height: 70
** width: 72  height: 70
** width: 21  height: 170
** width: 216  height: 50
** width: 1445  height: 38
** width: 21  height: 18
** width: 69  height: 52
** width: 18  height: 21
** width: 20  height: 45
** width: 30  height: 27
** width: 30  height: 44
** width: 86  height: 84
** width: 31  height: 21
** width: 51  height: 372
** width: 68  height: 66
** width: 21  height: 32
** width: 1920  height: 64
** width: 1920  height: 20
** width: 1099  height: 20
** width: 900  height: 64
** Creating image buffers
-----------createDC end-------------------

pLoadLevel in
Load level
ini checkpoints, and set cp game controls
------------------------------------
Reset level
IniAssets start
   iniEngine
Number of Stamps: 8
Number of Submarines: 27
Number of Artillery: 129
Number of Bad Guys: 44
Number of Static: 111

UnrollBK in
UnrollBK on
CreateMiniMap
WM==Create end **********************
gameloop is ready

HSE

A little crash:CPU Disasm
Address   Hex dump          Command                                  Comments
76BB6995  |>  56            PUSH ESI                                 ; /Arg1 = 130
76BB6996  |.  E8 95050000   CALL 76BB6F30                            ; \USP10.76BB6F30      <-- CRASH

Another:CPU Disasm
Address   Hex dump          Command                                  Comments
758EC602  /$  8BFF          MOV EDI,EDI                              ; HEXDATA kernel32.InterlockedExchange(pTarget,Value)
758EC604  |.  55            PUSH EBP                      <-- CRASH
758EC605  |.  8BEC          MOV EBP,ESP
758EC607  |.  5D            POP EBP
758EC608  \.- E9 0BFFFFFF   JMP 758EC518


And sometime not error, but not aeroplane!!

LATER:
                 :biggrin:

<----------      AMD  Win7-32 
Equations in Assembly: SmplMath

LordAdef

Which windows HSE?

I built it with Windows 10