Jump to content

Photo

Navi Feature (FFC Script)


  • Please log in to reply
23 replies to this topic

#1 Cukeman

Cukeman

    "Tra la la, look for Sahasrahla. ... ... ..."

  • Banned
  • Location:Hyrule/USA

Posted 27 February 2016 - 01:37 PM

Let's discuss whether or not this script is possible and what the options are before I actually make the request.

 

The idea is that when the player presses EX1:

• Link and Enemies stop whatever they're doing (as if Link had pressed the pause button)

• Link's movement and controls are disabled

• The contents of Screen D3 (Navi's image/text hint) are drawn on Layer 6 (preferably above Layer 6 - if possible)

 

When the player presses EX2:

• Link and Enemies resume whatever they're doing (as if Link had pressed the pause button again)

• Link's movement and controls are enabled

• The contents of Screens D3, D4, D5, D6 and D7 are "undrawn"

 

D0: "Hey!" SFX (Sound to play [only once] 3.5 seconds after Screen Init)

D1: "Listen!" SFX (Sound to play when EX1 is pressed)

D2: "Cancel" SFX (Sound to play when EX2 is pressed)

D3: 1st Screen to draw

D4: 2nd Screen to draw

D5: 3rd Screen to draw

D6: 4th Screen to draw

D7: 5th Screen to draw

 

Further Details :

 

EX1:

• Calls up Screen D3

• Advances from D3 to D4 on next press (unless D4 is set to 0)

• Advances from D4 to D5 on next press (if D5 is set to 0, advances to D3 instead)

• Advances from D5 to D6 on next press (if D6 is set to 0, advances to D3 instead)

• Advances from D6 to D7 on next press (if D7 is set to 0, advances to D3 instead)

• Advances from D7 to D3 on next press

 

Arguments D3-D7:

I'm not sure what number you'd type in to specify the desired DMap and Screen

 

P.S. Maybe this script would work better if D3 and up were drawn over the pause screen instead of the regular screen? But then item selection would have to de disabled.


Edited by Cukeman, 27 February 2016 - 02:44 PM.


#2 Timelord

Timelord

    The Timelord

  • Banned
  • Location:Prydon Academy

Posted 28 February 2016 - 01:28 AM

I'm just going to say, that a Navi feature has been done, and it is possible. Saffith's Tango.zh makes it pretty easy to implement, however you wish.

 

There are a few existing helper faerie scripts out there to; but if you want an example, Shoelace is using Tango to do this in a somewhat non-intrusive fashion.

 

Unless you actually want to use this, putting up proof of concept code is somewhat of a waste, as it's complex to make;and if I do, it would require a good amount of effort.

 

If you want per-screen information, the easiest way is to make the faerie a global object script, and text display global with Tango. Then, put an ffc on each screen where information is given, that feeds strings to the global script's buffer. You can also do this with multiple ffcs, and feed display information based on Proximity*(), which is a function that I added to std.zh for things of this sort.

 

It's similar to Collision(), but it takes into account only distance between two objects on one plane. Thus, ProximityX(ffc f) and ProximityY(ffc f). I need to expand this to include bool Proximity*(obj, int dist) and bool Proximity*(obj1,. obj2,. int dist). That's a useful addition, except that it'll be somewhat tedious, as I designed it to work with combos, which are also ints, so a simple overload isn't possible.

 

At present, the functions return the distance between any two objects, so you need to compare them; a boolean option would return if the objects are with a specified range, and would be immediately useful. I may do that as general Proximity(), returning if the objects are within that range on both planes, for that would make the most sense.

 

Here is a very basic Navi FFC, that might do the job for the average user.

 

 

...and here is something more complex, but incomplete:

 


Edited by ZoriaRPG, 28 February 2016 - 06:17 PM.


#3 Cukeman

Cukeman

    "Tra la la, look for Sahasrahla. ... ... ..."

  • Banned
  • Location:Hyrule/USA

Posted 28 February 2016 - 02:42 AM

It sounds more complex than I had anticipated, to say the least. I did do a search for Navi scripts on PureZC, but nothing came up, but then then I might not have used the search engine well enough. This isn't something I have any immediate plans to use, but it might be something to consider as the finishing touches on a quest, if I ever get that far.



#4 Timelord

Timelord

    The Timelord

  • Banned
  • Location:Prydon Academy

Posted 28 February 2016 - 04:45 PM

It sounds more complex than I had anticipated, to say the least. I did do a search for Navi scripts on PureZC, but nothing came up, but then then I might not have used the search engine well enough. This isn't something I have any immediate plans to use, but it might be something to consider as the finishing touches on a quest, if I ever get that far.

 

The reason that you aren't finding results, is because of both how quest-specific this type of script set would be, and also, because it is not really suited toward general implementation (difficulty in set-up). It wouldn't be that hard for me to make something like this, but I have zero need for it in my own projects, and setting it up (not to mention supporting it) would be painful.

 

I had an idea for a system where the player calls for advice, but that's a bit different.


Edited by ZoriaRPG, 28 February 2016 - 04:46 PM.


#5 Avaro

Avaro

    o_o

  • Members
  • Real Name:Robin
  • Location:Germany

Posted 28 February 2016 - 05:18 PM

Can't you make it play a message string instead of going through the trouble of freezing the screen and drawing stuff or using tango?



#6 Cukeman

Cukeman

    "Tra la la, look for Sahasrahla. ... ... ..."

  • Banned
  • Location:Hyrule/USA

Posted 28 February 2016 - 06:07 PM

Can't you make it play a message string instead of going through the trouble of freezing the screen and drawing stuff or using tango?

 

Certainly that would be another option. The wild idea I had in mind was displaying enemy illustrations alongside Navi's hints.



#7 Avaro

Avaro

    o_o

  • Members
  • Real Name:Robin
  • Location:Germany

Posted 28 February 2016 - 06:13 PM

Well then, the way you described it in your first post is possible to script. So that would be doable.

 

Not sure what you meant when you mentioned the pause screen though, since scripts don't run when the subscreen is opened. Or maybe you want a scripted pause screen?



#8 Cukeman

Cukeman

    "Tra la la, look for Sahasrahla. ... ... ..."

  • Banned
  • Location:Hyrule/USA

Posted 28 February 2016 - 06:17 PM

Well then, the way you described it in your first post is possible to script. So that would be doable.

 

Not sure what you meant when you mentioned the pause screen though, since scripts don't run when the subscreen is opened. Or maybe you want a scripted pause screen?

 

I just didn't know if pausing the game via scripting was possible (or easy), I thought that perhaps if pausing the screen made the script difficult to code, then it might be simpler to display navi's visual hints over the pause screen instead. Apparently not if scripts don't run when the subscreen is opened :P


Edited by Cukeman, 28 February 2016 - 06:19 PM.


#9 Avaro

Avaro

    o_o

  • Members
  • Real Name:Robin
  • Location:Germany

Posted 28 February 2016 - 06:21 PM

I just didn't know if pausing the game via scripting was possible (or easy)

 

Hm, there are two combo types that can handle screen freezing. One freezing ffcs only and the other freezes everything except ffcs. So what the script should be doing is putting combos with both of these combo types on the screen. If you want to freeze ffcs too, it can't be an ffc script though. If you want to freeze everything except ffcs, then this is very simple.



#10 Cukeman

Cukeman

    "Tra la la, look for Sahasrahla. ... ... ..."

  • Banned
  • Location:Hyrule/USA

Posted 28 February 2016 - 06:25 PM

Hm, there are two combo types that can handle screen freezing. One freezing ffcs only and the other freezes everything except ffcs. So what the script should be doing is putting combos with both of these combo types on the screen. If you want to freeze ffcs too, it can't be an ffc script though. If you want to freeze everything except ffcs, then this is very simple.

 

Well, the only thing I would be drawing on the screen is walkable (type: none) combos placed directly on their original screen (not via FFC).


Edited by Cukeman, 28 February 2016 - 06:26 PM.


#11 Timelord

Timelord

    The Timelord

  • Banned
  • Location:Prydon Academy

Posted 01 March 2016 - 06:09 AM

H

Well, the only thing I would be drawing on the screen is walkable (type: none) combos placed directly on their original screen (not via FFC).

`


Please be as explicit, and specific as possible. I have no idea what you plan to do with that, nor do I know how you plan to draw them. (Global active script?)

Using the simple ffc approach, drawing via the ffc would be ideal.

Edited by ZoriaRPG, 01 March 2016 - 06:20 AM.


#12 Cukeman

Cukeman

    "Tra la la, look for Sahasrahla. ... ... ..."

  • Banned
  • Location:Hyrule/USA

Posted 01 March 2016 - 08:16 AM

Please be as explicit, and specific as possible. I have no idea what you plan to do with that, nor do I know how you plan to draw them. (Global active script?)

Using the simple ffc approach, drawing via the ffc would be ideal.

 

I'm afraid my language was unclear. I basically just want to draw a screen size image over the current screen. I assumed the best way to do this was to draw the contents of another screen on the map. Let's say the player is on DMap0, Screen 2C, and the image I want drawn is the contents of DMap3, Screen 5E.

 

When I said "(not via FFC)" I meant that when I'm placing the combos on DMap3, Screen 5E (in ZQuest Editor) I won't be placing them via Screen > Freeform Combos.

 

Drawing the combos over DMap0, Screen 2C via FFC is perfectly fine. Sorry for the wording in the previous post.

 

EDIT: Also, I much prefer to use FFC scripts over Global Scripts whenever possible.


Edited by Cukeman, 01 March 2016 - 08:26 AM.


#13 grayswandir

grayswandir

    semi-genius

  • Members

Posted 01 March 2016 - 05:42 PM

Are you going to want this for every screen, or just a small portion?



#14 Cukeman

Cukeman

    "Tra la la, look for Sahasrahla. ... ... ..."

  • Banned
  • Location:Hyrule/USA

Posted 01 March 2016 - 08:24 PM

Are you going to want this for every screen, or just a small portion?

 

I'm a big fan of the instruction manual for Z1- the idea behind this script was to be able to call up the classic enemy illustration for each enemy along with a written description/hint so that I could incorporate that material back into the game. As you can tell, this is hardly a burning need, but it would make for a really fun and fancy little feature.

 

In other words, every screen. I also just realized that it might be helpful if the screen contents were drawn in the level palette of their DMap, not 100% necessary, but it would probably be quite helpful.

 

EDIT: This is another reason I saw this as a FFC Script,  because each screen would have a different selection of enemies.


Edited by Cukeman, 01 March 2016 - 08:26 PM.


#15 grayswandir

grayswandir

    semi-genius

  • Members

Posted 01 March 2016 - 08:41 PM

So, it's only going to be for enemies? You could probably set the script up to scan for enemies, and then show them in order.

Like, you'd dedicate map 10 to the script, and then you'd make screen 9 the hint for enemy id 9, etc.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users