Sign in to follow this  
rhumbaflappy

BGLC Syntax - Comments?

Recommended Posts

Hello Guys,I'm wondering how to put a large part of BGLC-code (ASM) into a comment. In my file I would have to insert hundrets of ";" for every line. I don't believe that this could be the solution.The two other well known possibilities "" or "/* COMMENT */" don't work in BGLC. Is there anyone who knows which syntax is supported by BGLC?ThanksSascha

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

Hi Sascha.MASM allows multiline commenting:Multiline comments can also be specified with the COMMENT directive. The assembler ignores all text and code between the delimiters or on the same line as the delimiters. This example illustrates the use of COMMENT.COMMENT ^ The assembler ignores this text^ mov ax, 1 and this codeMight be worth a try with BGLC.EDITED----------It does work. For sake of clarity, you might consider the start and end of the comment on their own lines. The following code only draws half the intended triangles in the code:

; NonAlphaMyTree_NonAlpha label BGLCODE	MATERIAL 0, -1	BGL_TEXTURE TEXTURE_BUILDING+ TEXTURE_SPRING+ TEXTURE_FALL+ TEXTURE_WINTER+ TEXTURE_HARDWINTER+ TEXTURE_NIGHTMAP, 0F007h, "treetexture.bmp"	DRAW_TRI_BEGIN 0, 16	DRAW_TRI   13,  15,   1; poly=2 part=0	DRAW_TRI   14,  12,   2; poly=3 part=0	DRAW_TRI	0,   2,  12; poly=4 part=0	DRAW_TRI   11,   7,   9; poly=5 part=0COMMENT ^		DRAW_TRI	5,   9,   7; poly=6 part=0	DRAW_TRI	8,   4,  10; poly=7 part=0	DRAW_TRI	6,  10,   4; poly=8 part=0	DRAW_TRI	3,   1,  15; poly=1 part=0^	DRAW_TRI_END	BGL_END	BGL_RETURN

Dick

Share this post


Link to post
Share on other sites

Yehaa! It works! Thanks, Dick!And finally I'm so advanced that I ask questions that even Arno can't answer. :)Sasa

Share this post


Link to post
Share on other sites

Hi Sasa.BGLC is a subset of MASM. Some designers actually use MASM rather than BGLC. But BGLC has everything we need.Here's a link to MASM info:http://webster.cs.ucr.edu/Page_TechDocs/MASMDoc/The downloadable MASM Programmers Guide guide in Word format:http://webster.cs.ucr.edu/AsmTools/MASM/MA...ersguide611.zipThe downloadable MASM Reference Guide in Word format:http://webster.cs.ucr.edu/AsmTools/MASM/MA...eference611.zipDick

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this