In Progress [ORIGINAL] Shinobi Densetsu (HELP NEEDED!)

The project is currently under development.
great tips, everyone!

I started work on the UI yesterday, and bumped immediately into trouble:

my HP/MP meters aren't bars, they're animations.

made a "none" type model for the HP meter, with the intention of running a simple script that checks max HP and current HP and selects the right frame but I don't know how to stop the entity from scrolling and how to draw it permanently in the UI layer. (this last part is sorted out)

it loads perfectly, and spawns inside the level. I even tried "panel" type with speed 0, maybe the coordinates are wrong, I didn't have much time to debug.
but it still scrolls away when the camera moves

in other engines I would spawn an invisible container object at the UI root coordinate and have it spawn modules relative to this position.

how would this be done in OpenBOR?
(figured out, just need to get the objects to stick to the screen)



as for the loading screen, if the feature wasn't stripped or modified, I found some legacy methods in the manual. the loading screens are customizable to some extent and I'm happy with that.

that example didn't have mouse support as well. the whole menu is "fake", in the sense that the cursor is a player entity and every icon has its own scripts attached. closest I can think of in OpenBOR is using the attack hitbox to process clicks and the rest is down to scripts/entities. i can definitely change the order in which screens and menus appear to fit the engine defaults.

1. logo/intro
2. default main menu
3. character select
4. custom game menu (in level)
5. actual game level
 
Last edited:
Animations and sounds/music can be done during load, you just have to make sure everything you want to use during a load screen is already in memory. You can even do scrolling too. See this selection screen. It's all done with sprites drawn from memory to a sub-screen and scrolled with script.
Yeah I know about select screen (btw I read your code for that select and I didn't understood almost nothing lol), I am talking about load screen. Last time I tried, the music got interrupted a lot during load - even if I loaded the music beforehand .
 
Yeah I know about select screen (btw I read your code for that select and I didn't understood almost nothing lol), I am talking about load screen.

It will work in load screen too. In fact, that was the original purpose for that code and I've tested it as such.

The catch is that it's a solution looking for a problem. Levels load so fast there's just no point in most cases.

I'm just letting you know the option is there.

Last time I tried, the music got interrupted a lot during load - even if I loaded the music beforehand .

That's why you have to do it with sound effects (which I admit is a PITA to use for music in current versions). The music channel won't work because it's streamed,.

Again, these are just options.

DC
 
Last edited:
by the way, I assume I'm using v4 because I updated the engine with the current downloadable files. so I should be able to use the latest feature set.

I still haven't had any success with the faux UI,

in fact I did, I have the HP meter showing but still no behavior. now the problem is that I can't stop it from scrolling, which is the opposite of what I need.
Object header:

Code:
name UI_HP
type none
gfxshadow    0
speed   10
subject_to_screen 0
subject_to_gravity 0
subject_to_basemap 0
setlayer   800
scroll 0.0

from OpenBOR 4.0 thread:
none of the suggested methods worked for me. panel type and speedf 0.0 or none type with scroll 0.0 and gravity/terrain off , both make the entity follow the level panels when the camera moves. any values other than 0 moves/scrolls the object and that's not the intended result.
any ideas?
 
Last edited:
Nice work overall, just beware of the blurry rendering of these background elements stretched.
They are some ways to avoid that I think.
 
  • Like
Reactions: kzr
Nice work overall, just beware of the blurry rendering of these background elements stretched.
They are some ways to avoid that I think.
based on the demo material, I agree, but bear in mind this was just a test to see how everything works, the final visuals will be more refined and consistent.

Bumping so it doesn't get buried in the edits and replies :

previous post asking for help
 
Last edited:
  • Like
Reactions: NED
I hope this is the right place. may I suggest the option to use entities as UI elements?
none of the suggested methods worked for me. panel type and speedf 0.0 or none type with scroll 0.0 and gravity/terrain off , both make the entity follow the level panels when the camera moves. any values other than 0 moves/scrolls the object and that's not the intended result.
I don't want to drag this into a help thread. I've asked this before in my own thread and if it's my fault it's not working, feel free to continue the discussion there.
@kzr I'm a bit late in the topic, but are you trying to use entity as hud elements? If yes, like @DCurrent said, you can easily make it with some adjustments using panel entities, no need to change the engine.

This one will make the panel entity to move at the same scrolling speed, look in the example below how the light effect will move.
C:
name    St1_Light
type    panel
speed    5
scroll    0.5

 
Last edited:
@kzr I'm a bit late in the topic, but are you trying to use entity as hud elements? If yes, like @DCurrent said, you com easily make it with the some adjusments using panel entities, no need to change the engine.

This one will make the panel entity moves at the same scrolling speed, look in the example below how the light effect will move.
C:
name    St1_Light
type    panel
speed    5
scroll    0.5

that didn't work as well. could it be because my level scrolls in both axes, and yours only horizontally?
 
What exactly happened? It should work on the same way as I shown in the video.
it's hard to explain precisely, but the entity disappears from its origin suggesting it scrolled too far away or bugged out. if I use speedf 0 and scroll 0 the model is where it should but as soon as the camera moves, it moves too
 
it's hard to explain precisely, but the entity disappears from its origin suggesting it scrolled too far away or bugged out. if I use speedf 0 and scroll 0 the model is where it should but as soon as the camera moves, it moves too
I have some questions:

- what engine build you are using?
- what adjustments your level is using (please, post the header)
- how your panel entity is configured (please, post the header)
- how are you spawning the panel entity?
 
I have some questions:

- what engine build you are using?
- what adjustments your level is using (please, post the header)
- how your panel entity is configured (please, post the header)
- how are you spawning the panel entity?
Build - latest available (7556)

Level Header:
Code:
background    Data/Bgs/hirogawa/test.png  0.95  1.05  0  -160  0  0  5000  1  1  0

panel        data/levels/hirogawa/bridge.png none none


order    a

settime  0
notime  1
direction  both
cameratype 1
scrollspeed 8

spawn1  52  139  64

entity header:

Code:
name UI_HP
type panel

speedf 0
scroll 0

entity is spawned by the level

Code:
spawn UI_HP
coords 48 800 48
 
Build - latest available (7556)

Level Header:
Code:
background    Data/Bgs/hirogawa/test.png  0.95  1.05  0  -160  0  0  5000  1  1  0

panel        data/levels/hirogawa/bridge.png none none


order    a

settime  0
notime  1
direction  both
cameratype 1
scrollspeed 8

spawn1  52  139  64

entity header:

Code:
name UI_HP
type panel

speedf 0
scroll 0
Ok, I will test these configurations in my game.

entity is spawned by the level

Code:
spawn UI_HP
coords 48 800 48
It seems that the "at" is missing in this part.
 
@kzr Ok, I was able to make it work using your adjustments except for the speed/scroll.


Indeed your speedf/scroll at zero will not move but they in fact are working as intended, once zero means no speed. Considering that the camera is moving at a certain "speed", zero means they will stay exactly where they are spawned.
 
Moved the discussion about model position and scroll from OpenBOR 4.0 thread. @kzr, just glancing I am not sure what's going on. I sort of neglected to finish a paper that has to be done by Sunday, but I will try and poke around someone if you and @Kratus don't find a fix soon.

I do know a couple of other solutions to try, but they shouldn't really be necessary for this if I understand what you're doing.

DC
 
Last edited:
I'm not having the same luck
Very strange, looks like two totally different behaviours using the same engine lol. I can take a look at your game if you don't mind, I need to understand what's going on.
 
Very strange, looks like two totally different behaviours using the same engine lol. I can take a look at your game if you don't mind, I need to understand what's going on.
sure, I'll share the dropbox folder in a private message
 
Back
Top Bottom