It is currently Sat Nov 18, 2017 3:27 am

All times are UTC - 7 hours





Post new topic Reply to topic  [ 14 posts ] 
Author Message
PostPosted: Sun Jun 18, 2017 3:27 pm 
Offline
User avatar

Joined: Sun Jun 11, 2017 5:39 pm
Posts: 39
First thank to all the people who helped me so far. I've been hacking for almost 10 years and I always coded with FCEUXD (debugger). I recently decided to use easier program, and I ask advices from people here. I got a lot of help and useful informations. I ended up picking Eclipse to code, it answered my needs.

However, I have few more points for which I would need help if possible. I will write few small questions:

Related with Eclipse (ASM6 to compile):

1-) Is there a way to comment all selected line and decomment them, like with Visual Studio?
2-) If I use multiple document, for example I will have main file which will include everything. I will first include the variables, then for example, a boss file. However the boss files has no include but uses variable from the file loaded before in the main file.

Is there a way to see the variable in Eclipse to the right when I edit the boss file even if it has no include?

3-) I would like Eclipse to propose me the variable to the right when I start typing, like visual studio. Is it possible?

4-) Considering I have a main file that does all the include like mentionned above, can I have private labels?

For example, in every boss file, I will have labels at each RTS for the BEQ, BNE, JMP, etc...

RTS0:
RTS
.
.
.
RTS1:
RTS

But these label would refer to different things in every boss file. Is there a way to be able to use labels as RTS0, RTS1 as private in every file?


Last edited by MartsINY on Sun Jun 18, 2017 4:12 pm, edited 1 time in total.

Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 4:07 pm 
Offline

Joined: Sun Sep 19, 2004 11:12 pm
Posts: 19222
Location: NE Indiana, USA (NTSC)
Which assembler are you using? In ca65, labels are private by default.


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 4:12 pm 
Offline
User avatar

Joined: Sun Jun 11, 2017 5:39 pm
Posts: 39
tepples wrote:
Which assembler are you using? In ca65, labels are private by default.


ASM6, added it to description!!


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 4:20 pm 
Offline
User avatar

Joined: Sat Jan 03, 2015 5:58 pm
Posts: 368
Location: ...
Can't help you with eclipse, but for private labels, try making local labels with @.
Code:
@loop: jmp @loop
bla:
@loop: jmp @loop

The above shold work okay. Well, should.


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 5:27 pm 
Offline
User avatar

Joined: Sun Jun 11, 2017 5:39 pm
Posts: 39
nicklausw wrote:
Can't help you with eclipse, but for private labels, try making local labels with @.
Code:
@loop: jmp @loop
bla:
@loop: jmp @loop

The above shold work okay. Well, should.


doesn't seem to work for ASM6. Any label with @ is not recognised


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 7:04 pm 
Offline
User avatar

Joined: Sat Feb 12, 2005 9:43 pm
Posts: 10112
Location: Rio de Janeiro - Brazil
ASM6's README.TXT cleary states these are valid local labels:

Quote:
Labels beginning with '@' are local labels. They have limited scope,
visible only between non-local labels. Names of local labels may be reused.


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 7:18 pm 
Offline
User avatar

Joined: Sun Jun 11, 2017 5:39 pm
Posts: 39
tokumaru wrote:
ASM6's README.TXT cleary states these are valid local labels:

Quote:
Labels beginning with '@' are local labels. They have limited scope,
visible only between non-local labels. Names of local labels may be reused.


I saw this too... but when I do this it doesn't work. For example:

@a:
RTS
LDA spriteAnimation,X
CMP #drillManSprite_StandingFacingScreenRotatingDrills_FinalAnimatino
BNE @a

or

BNE a

Both don't work and I don't see in the README more detail about this...


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 7:20 pm 
Offline
User avatar

Joined: Sat Feb 12, 2005 9:43 pm
Posts: 10112
Location: Rio de Janeiro - Brazil
Have you tried a name other than "a"? It may be interpreting that "a" as the accumulator.


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 7:22 pm 
Offline
User avatar

Joined: Sun Jun 11, 2017 5:39 pm
Posts: 39
unfortunately yes, but I always get unknown label...


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 7:29 pm 
Offline
User avatar

Joined: Sat Feb 12, 2005 9:43 pm
Posts: 10112
Location: Rio de Janeiro - Brazil
Oh well, I never use local labels with ASM6 anyway, so I can't say what's going on. I use temporary labels instead:

Code:
-loop: jmp -loop
;something here
-loop: jmp -loop


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 7:31 pm 
Offline
User avatar

Joined: Sun Jun 11, 2017 5:39 pm
Posts: 39
tokumaru wrote:
Oh well, I never use local labels with ASM6 anyway, so I can't say what's going on. I use temporary labels instead:

Code:
-loop: jmp -loop
;something here
-loop: jmp -loop


Using those ones also, they are better but in rare case a local variable would be useful, but I can do withouth


Top
 Profile  
 
PostPosted: Sun Jun 18, 2017 9:37 pm 
Offline

Joined: Sun May 03, 2015 8:19 pm
Posts: 89
If you are using the WUDSN IDE make sure its definitely associated with the right assembler...


Top
 Profile  
 
PostPosted: Mon Jun 19, 2017 3:14 am 
Offline
User avatar

Joined: Sun Jun 11, 2017 5:39 pm
Posts: 39
yes it is!!

anyway for now I compile it with ASM6, not through Eclipse


Top
 Profile  
 
PostPosted: Mon Jun 19, 2017 9:43 am 
Offline

Joined: Sun May 03, 2015 8:19 pm
Posts: 89
Ok just checking.

I remember I had to make this change in the IDE preferences to get it to work right.

Under Window->preferences->Editors->File Associations

MADS was the default editor for *.asm files. I had to remove it as the default and make ASM6 the default editor for that file type.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 14 posts ] 

All times are UTC - 7 hours


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group