Skeetendo

’Cause all games were better on the GBC

You are not logged in.

#1 2018-03-07 14:32:59

TheRealLazerBlazer22
Member
From: United States
Registered: 2018-03-02
Post 3/10

(PokéRed) New to the Scene and Receiving Errors

Some of what is written here will come from my post in the "Simple Questions and Answers" thread. I hope that is okay.

I'm still trying to wrap my head around assembly, and seem alright in following "tutorials" and such, but striking out on my own, seems a little out of my reach at the moment. Though, I am experimenting with it on the side to learn as I progress.

I actually have several questions, but the most pressing matter at the moment is the error I receive while compiling.
I'm sure it's a very simple fix that I'm missing since I'm quite new to this, but I figured it couldn't hurt to ask for help, as I'm quite lost on what to check or do to solve it.

The error is listed below:

rgbasm -D _RED -h -o main_red.o main.asm
ERROR: main.asm(215):
        Unterminated string
make: *** [Makefile:37: main_red.o] Error 5


So far, what I've come to understand is, "main.asm(215)" refers to line 215 in main.asm.

So far, so good. Though, I do not know where to go from here. Line 215 is where I modified this, following Mateo's tutorial.

The code is listed below:

SECTION "NPC Sprites 2", ROMX, BANK[NPC_SPRITES_2]

RedCyclingSprite:     INCBIN "gfx/sprites/cycling.2bpp"
RedSprite:            INCBIN "gfx/sprites/red.2bpp"
JamesSprite:          INCBIN "gfx/sprites/james.2bpp
JamesCyclingSprite:   INCBIN "gfx/sprites/jamescycling.2bpp 
BlueSprite:           INCBIN "gfx/sprites/blue.2bpp"
OakSprite:            INCBIN "gfx/sprites/oak.2bpp"
BugCatcherSprite:     INCBIN "gfx/sprites/bug_catcher.2bpp"
SlowbroSprite:        INCBIN "gfx/sprites/slowbro.2bpp"
LassSprite:           INCBIN "gfx/sprites/lass.2bpp"
BlackHairBoy1Sprite:  INCBIN "gfx/sprites/black_hair_boy_1.2bpp"
LittleGirlSprite:     INCBIN "gfx/sprites/little_girl.2bpp"
BirdSprite:           INCBIN "gfx/sprites/bird.2bpp"
FatBaldGuySprite:     INCBIN "gfx/sprites/fat_bald_guy.2bpp"
GamblerSprite:        INCBIN "gfx/sprites/gambler.2bpp"
BlackHairBoy2Sprite:  INCBIN "gfx/sprites/black_hair_boy_2.2bpp"
GirlSprite:           INCBIN "gfx/sprites/girl.2bpp"
HikerSprite:          INCBIN "gfx/sprites/hiker.2bpp"
DaisySprite:          INCBIN "gfx/sprites/daisy.2bpp"
BikerSprite:          INCBIN "gfx/sprites/biker.2bpp"
SailorSprite:         INCBIN "gfx/sprites/sailor.2bpp"
CookSprite:           INCBIN "gfx/sprites/cook.2bpp"
BikeShopGuySprite:    INCBIN "gfx/sprites/bike_shop_guy.2bpp"
MrFujiSprite:         INCBIN "gfx/sprites/mr_fuji.2bpp"
GiovanniSprite:       INCBIN "gfx/sprites/giovanni.2bpp"
RocketSprite:         INCBIN "gfx/sprites/rocket.2bpp"
MediumSprite:         INCBIN "gfx/sprites/medium.2bpp"
WaiterSprite:         INCBIN "gfx/sprites/waiter.2bpp"
ErikaSprite:          INCBIN "gfx/sprites/erika.2bpp"
MomGeishaSprite:      INCBIN "gfx/sprites/mom_geisha.2bpp"
BrunetteGirlSprite:   INCBIN "gfx/sprites/brunette_girl.2bpp"
LanceSprite:          INCBIN "gfx/sprites/lance.2bpp"
MomSprite:            INCBIN "gfx/sprites/mom.2bpp"
BaldingGuySprite:     INCBIN "gfx/sprites/balding_guy.2bpp"
YoungBoySprite:       INCBIN "gfx/sprites/young_boy.2bpp"
GameboyKidSprite:     INCBIN "gfx/sprites/gameboy_kid.2bpp"
ClefairySprite:       INCBIN "gfx/sprites/clefairy.2bpp"
AgathaSprite:         INCBIN "gfx/sprites/agatha.2bpp"
BrunoSprite:          INCBIN "gfx/sprites/bruno.2bpp"
LoreleiSprite:        INCBIN "gfx/sprites/lorelei.2bpp"
SeelSprite:           INCBIN "gfx/sprites/seel.2bpp"


Line 215, as you might have guessed, is: "JamesSprite:          INCBIN "gfx/sprites/james.2bpp"

James has replaced Leaf in Mateo's tutorial. Instead of giving the option between Red and Leaf, you now have the option between Ash and James.

I'm hoping to add in some minor story differences along the road as well.

Regardless, I am currently in the process of retracing my steps and checking everything, as I am unable to continue modifications until I can get this resolved. As, for example, I am unable to access Pallet Town, in which I am currently trying to figure out how to add a new Pokémon Center, and a few houses.

I feel as though I am asking for a lot, and for that I apologize. I just feel in this scenario, it would be wise to ask for help instead of wandering near aimlessly.

If it is okay, and you have time, mind if I ask a few more questions? (These are less important than those listed above, but are still helpful.)

How would I go about adding in an EXP Bar?
I know in the textures for Blue that they exist, would I just have to code it in properly or would copying it from G/S/C be faster?

How would I go about changing the opening cut-scene and the copyright information? Just edit the files and import them back in? Though I know the cut-scene would be more complicated than that.

How would I go about making Running Shoes that are able to be equipped?


Thank you so very much for your time, and take care. -- Rob.

Last edited by TheRealLazerBlazer22 (2018-03-07 14:33:40)


Currently working on Pokémon Shiro Version.

Pokémon Shiro Version 0.05a Release:
Pokémon Shiro Version 0.05a IPS Download Link

"The human heart and true love obey no timetables."
"I'll create my own Destiny, even if I have to will it into existence."

Offline

#2 2018-03-07 16:25:26

Rangi
Member
Registered: 2016-05-09
Post 838/870

Re: (PokéRed) New to the Scene and Receiving Errors

ERROR: main.asm(215):
        Unterminated string

means you have an "Unterminated string" on line 215 of main.asm.

You correctly identified line 215 as:

JamesSprite:          INCBIN "gfx/sprites/james.2bpp

So just terminate the string.

Last edited by Rangi (2018-03-07 16:25:39)


Pokémon Polished Crystal (GitHub) — version 2.2.0 released
Pokémon Red★ and Blue★: Space World Edition (GitHub) — updated August 19!
Polished Map: pokered+pokecrystal map, tileset, and palette editor — version 3.5.1 released!

Offline

#3 2018-03-08 00:00:01

TheRealLazerBlazer22
Member
From: United States
Registered: 2018-03-02
Post 4/10

Re: (PokéRed) New to the Scene and Receiving Errors

Rangi wrote:
ERROR: main.asm(215):
        Unterminated string

means you have an "Unterminated string" on line 215 of main.asm.

You correctly identified line 215 as:

JamesSprite:          INCBIN "gfx/sprites/james.2bpp

So just terminate the string.

How would I go about doing that? Just delete the line from main.asm and replace it with another character (ala Gentleman/Swimmer/etc.)? Though, by doing that, I'm not sure if James will still load properly after being an option.

Also, thank you Rangi for getting back to me. I'll be giving this a shot as soon as possible, and see if my theory is correct.


Currently working on Pokémon Shiro Version.

Pokémon Shiro Version 0.05a Release:
Pokémon Shiro Version 0.05a IPS Download Link

"The human heart and true love obey no timetables."
"I'll create my own Destiny, even if I have to will it into existence."

Offline

#4 2018-03-08 00:09:19

Fotomac
Member
Registered: 2015-10-25
Post 301/332

Re: (PokéRed) New to the Scene and Receiving Errors

I think he means add a quotation mark at the end of the line.

Offline

#5 2018-03-08 00:58:03

TheRealLazerBlazer22
Member
From: United States
Registered: 2018-03-02
Post 5/10

Re: (PokéRed) New to the Scene and Receiving Errors

Fotomac wrote:

I think he means add a quotation mark at the end of the line.

Thanks so much. I feel like a dumbass for overthinking it.

Though, now I am receiving this error.

rgbasm -D _RED -h -o main_red.o main.asm
rgblink -n pokered.sym -l pokered.link -o pokered.gbc audio_red.o main_red.o text_red.o wram_red.o
error: Unable to place 'Battle (bank C)' (ROMX section) at $7FB1 in bank $0C
make: *** [Makefile:47: pokered.gbc] Error 1

I assume by adding in these code strings I have displaced where the code normally checks for the battle information, and thus, I have to change it.

My current bank looks like this.

SECTION "Battle (bank C)", ROMX, BANK[$C]
INCLUDE "engine/battle/moveEffects/mist_effect.asm"
INCLUDE "engine/battle/moveEffects/one_hit_ko_effect.asm"

Though I am unsure as to what .asm I need to modify, I am going to look around and try to find it and see what I can figure out.

Again, thanks so much Fotomac and Rangi for all your help.

Last edited by TheRealLazerBlazer22 (2018-03-08 01:10:57)


Currently working on Pokémon Shiro Version.

Pokémon Shiro Version 0.05a Release:
Pokémon Shiro Version 0.05a IPS Download Link

"The human heart and true love obey no timetables."
"I'll create my own Destiny, even if I have to will it into existence."

Offline

#6 2018-03-08 16:08:45

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,078/1,119

Re: (PokéRed) New to the Scene and Receiving Errors

In the original red, bank $C (and the nearby banks) was used for Pokemon pics. Most of these banks have a tiny bit of battle engine code wedged in at the bottom.
The good news is that it doesn't even really matter which bank these small bits of battle code are in.

Currently, the line "SECTION "Battle (bank C)", ROMX, BANK[$C]" means put this code at the next available position in bank $C.
You could change it to "SECTION "Battle (bank C)", ROMX" which simply means let the linker choose a bank to put this code wherever it fits.

Since the goal of vanilla pokered is to match the original rom perfectly, we have to specify to put it in bank $C. But when you are making a mod, you don't need to care about matching the original game in this way, so you can go ahead and let the linker choose where to put it.

Offline

#7 2018-03-08 16:35:53

TheRealLazerBlazer22
Member
From: United States
Registered: 2018-03-02
Post 6/10

Re: (PokéRed) New to the Scene and Receiving Errors

Danny-E 33 wrote:

In the original red, bank $C (and the nearby banks) was used for Pokemon pics. Most of these banks have a tiny bit of battle engine code wedged in at the bottom.
The good news is that it doesn't even really matter which bank these small bits of battle code are in.

Currently, the line "SECTION "Battle (bank C)", ROMX, BANK[$C]" means put this code at the next available position in bank $C.
You could change it to "SECTION "Battle (bank C)", ROMX" which simply means let the linker choose a bank to put this code wherever it fits.

Since the goal of vanilla pokered is to match the original rom perfectly, we have to specify to put it in bank $C. But when you are making a mod, you don't need to care about matching the original game in this way, so you can go ahead and let the linker choose where to put it.

I sincerely appreciate the help Danny. Thank you. However, now I constantly receive an "Unterminated string" error on this line.
I'll see what I can do to figure it out.

The error message looks like this:

rgbasm -D _RED -h -o main_red.o main.asm
ERROR: main.asm(818):
        Unterminated string
make: *** [Makefile:37: main_red.o] Error 5


I made sure that the quotation marks were in place, I tried moving them around along with the comma, to no avail. Hopefully I'll figure this out soon, so I'm able to work on the next part of my project. I sincerely appreciate all the help and I apologize for asking so many questions. Thank you all.

For reference, I set it back to the way to told me to, and it gives this error all the same.

The current code looks like this:

SECTION "Battle (bank C)", ROMX"
INCLUDE "engine/battle/moveEffects/mist_effect.asm"
INCLUDE "engine/battle/moveEffects/one_hit_ko_effect.asm"


Regardless, thanks again Danny for all your help, and for everyone else willing to lend me a hand. Thank you.

Last edited by TheRealLazerBlazer22 (2018-03-08 16:46:51)


Currently working on Pokémon Shiro Version.

Pokémon Shiro Version 0.05a Release:
Pokémon Shiro Version 0.05a IPS Download Link

"The human heart and true love obey no timetables."
"I'll create my own Destiny, even if I have to will it into existence."

Offline

#8 2018-03-08 16:43:47

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,079/1,119

Re: (PokéRed) New to the Scene and Receiving Errors

To clarify, the SECTION line that I am suggesting you change should look just like this:

SECTION "Battle (bank C)", ROMX

Remove that trailing quotation mark at the end.

Last edited by Danny-E 33 (2018-03-08 16:48:43)

Offline

#9 2018-03-08 16:48:44

TheRealLazerBlazer22
Member
From: United States
Registered: 2018-03-02
Post 7/10

Re: (PokéRed) New to the Scene and Receiving Errors

I apologize, I was editing the previous message as we speak. The code is now listed. I have tried with and without quotations, and either receive the Unterminated string error, or the previous error again. Thanks again Danny.

For example, by removing the quotation mark, I receive this once more:

rgbasm -D _RED -h -o main_red.o main.asm
rgblink -n pokered.sym -l pokered.link -o pokered.gbc audio_red.o main_red.o text_red.o wram_red.o
error: Unable to place 'Battle (bank C)' (ROMX section) at $7FB1 in bank $0C
make: *** [Makefile:47: pokered.gbc] Error 1

Last edited by TheRealLazerBlazer22 (2018-03-08 16:50:28)


Currently working on Pokémon Shiro Version.

Pokémon Shiro Version 0.05a Release:
Pokémon Shiro Version 0.05a IPS Download Link

"The human heart and true love obey no timetables."
"I'll create my own Destiny, even if I have to will it into existence."

Offline

#10 2018-03-08 16:50:31

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,080/1,119

Re: (PokéRed) New to the Scene and Receiving Errors

When you say you receive the previous error, does it mention a different section not being able to fit, or does it still mention the section "Battle (bank C)"?

Offline

#11 2018-03-08 17:11:54

TheRealLazerBlazer22
Member
From: United States
Registered: 2018-03-02
Post 8/10

Re: (PokéRed) New to the Scene and Receiving Errors

Danny-E 33 wrote:

When you say you receive the previous error, does it mention a different section not being able to fit, or does it still mention the section "Battle (bank C)"?

It still mentions it like before. The error I posted in my last post, was taken from the most recent attempt at compiling.

If you'd like to take a look, I can post the main.asm on Google Drive.

I also apologize for the delay.

https://drive.google.com/open?id=1dqZ1q … hY_xUeWRHU

Last edited by TheRealLazerBlazer22 (2018-03-08 17:23:27)


Currently working on Pokémon Shiro Version.

Pokémon Shiro Version 0.05a Release:
Pokémon Shiro Version 0.05a IPS Download Link

"The human heart and true love obey no timetables."
"I'll create my own Destiny, even if I have to will it into existence."

Offline

#12 2018-03-08 17:35:43

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,081/1,119

Re: (PokéRed) New to the Scene and Receiving Errors

I just remebered that the problem has to do with the linkerscript, pokered.link, which is a pretty new addition to the project.

In pokered.link, you will see these lines:

ROMX $C
  "Pics 4" ; PICS_4
  "Battle (bank C)"

It should be safe to comment out the battle section by changing it to this:

ROMX $C
  "Pics 4" ; PICS_4
;  "Battle (bank C)"

Offline

#13 2018-03-08 17:58:54

TheRealLazerBlazer22
Member
From: United States
Registered: 2018-03-02
Post 9/10

Re: (PokéRed) New to the Scene and Receiving Errors

Danny-E 33 wrote:

I just remebered that the problem has to do with the linkerscript, pokered.link, which is a pretty new addition to the project.

In pokered.link, you will see these lines:

ROMX $C
  "Pics 4" ; PICS_4
  "Battle (bank C)"

It should be safe to comment out the battle section by changing it to this:

ROMX $C
  "Pics 4" ; PICS_4
;  "Battle (bank C)"

Oh thank God... with a little more bug fixing on my end... it works. Say, Danny, would you mind taking a look at it so far in the beginning and helping me understand the graphical errors on the title screen and when selecting? I'm not exactly sure what to do about it, especially on the title screen, without entirely re-colouring it. Also, any tips at all on my sprites or anything would be extremely helpful to me.

When selecting, I may just have to make the box smaller, though I'm not sure.

I'll provide an IPS here for you, if you want to take a look. Regardless, thank you so much Danny. I couldn't have done it without all of you.

IPS: https://drive.google.com/open?id=1DvKH9 … s6c9KoUkMr


Currently working on Pokémon Shiro Version.

Pokémon Shiro Version 0.05a Release:
Pokémon Shiro Version 0.05a IPS Download Link

"The human heart and true love obey no timetables."
"I'll create my own Destiny, even if I have to will it into existence."

Offline

#14 2018-03-08 18:45:00

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,082/1,119

Re: (PokéRed) New to the Scene and Receiving Errors

I took a look at your hack. The problem you are having is that the original graphic of the player on the title screen has a pokeball that bounces up and down when a starter mon leaves the screen.
With your new graphic, the tile that was a pokeball is now part of the body of the character.
To fix this, you should remove the code that modifies the y coordinate of this tile.
The related routines are in engine/titlescreen2.asm

Also, since you are using the disassembly, you should consider getting familiar with git.
As long as you don't mind your hack being public and open source, you should manage your repo publicly on Github.
That way, when you want me to take a look at a bug, I will just work off of your Github repo. Then you don't have to send me an ips patch.

EDIT:
As for the character selection screen, it seems the name "JAMES" is one too many characters wide to fit in the default Yes/No style box that you're using.
Unfortunately, without having all of your source code,  I can't easily investigate the problem.
I suspect that a fix would involve modifying engine/menu/text_box.asm

Last edited by Danny-E 33 (2018-03-08 18:48:42)

Offline

#15 2018-03-09 14:15:32

TheRealLazerBlazer22
Member
From: United States
Registered: 2018-03-02
Post 10/10

Re: (PokéRed) New to the Scene and Receiving Errors

Danny-E 33 wrote:

I took a look at your hack. The problem you are having is that the original graphic of the player on the title screen has a pokeball that bounces up and down when a starter mon leaves the screen.
With your new graphic, the tile that was a pokeball is now part of the body of the character.
To fix this, you should remove the code that modifies the y coordinate of this tile.
The related routines are in engine/titlescreen2.asm

Also, since you are using the disassembly, you should consider getting familiar with git.
As long as you don't mind your hack being public and open source, you should manage your repo publicly on Github.
That way, when you want me to take a look at a bug, I will just work off of your Github repo. Then you don't have to send me an ips patch.

EDIT:
As for the character selection screen, it seems the name "JAMES" is one too many characters wide to fit in the default Yes/No style box that you're using.
Unfortunately, without having all of your source code,  I can't easily investigate the problem.
I suspect that a fix would involve modifying engine/menu/text_box.asm


I will certainly look into GitHub in the near future and try to become familiar with it, as for now, I can send you a .zip file of my source code.

Source Code: https://drive.google.com/open?id=1y9mfI … AAZeKv0xLc

I tried modifying engine/titlescreen2.asm and I usually got one of two results. One where I was able to remove the PokéBall animation but the white box itself remained, and one where it wouldn't let me go past the title screen.

So, I reverted it back to the way it was prior for the moment. Though, I will be looking into my possibilities in engine/titlescreen2.asm.

Would it be better to just move the PokéBall location somewhere else in the title screen? Though, I don't think that suits the sprite, unless I animated James tossing it up and down somehow.

On another note, I tried modifying the text box width a few times in engine/menu/text_box.asm, and it didn't do anything, so I reverted back to it's previous state also.

I'm also trying to figure out how to add in a Pokémon Center to Pallet, to make it feel more like a town, comparative to a village. I've got the map set, but now I'm working on writing the warp and such. I thought about copying the data over from a previous Center, but there's two major drawbacks I have doing that. First, the people inside would be copied over as well, and two, you would originally exit into the town it was originally placed in.

I suppose I could modify that, but I'm sure there's a better way to do things. Any tips?

Last edited by TheRealLazerBlazer22 (2018-03-09 14:17:37)


Currently working on Pokémon Shiro Version.

Pokémon Shiro Version 0.05a Release:
Pokémon Shiro Version 0.05a IPS Download Link

"The human heart and true love obey no timetables."
"I'll create my own Destiny, even if I have to will it into existence."

Offline

Board footer

Powered by FluxBB