Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Diarandor

Pages: [1] 2 3 ... 64
You should not set the state to false when on_item_finished() is called by the engine, but call it yourself when the item action has TRULY finished.

Development / Re: Freezing/locking keyboard during specific event?
« on: June 14, 2018, 07:37:04 pm »
To do it in a clean way you'll need to modify the event on_command_pressed and do nothing if the item is being used. That will avoid annoying built-in stuff like the hero state and animations being restarted. As Max says, it is convenient to define item:is_being_used() (or item:can_be_used()) for all items.

Development / Re: How to make hero hurt while swimming
« on: June 13, 2018, 08:52:17 pm »
This seems to me an engine limitation, or even a bug.
@Christopho: should we open an issue for this?

It is still doable in Lua with some event (on_animation_changed or on_state_changed).

Development / Re: function vs. function:enemy
« on: June 11, 2018, 08:34:21 pm »
The keyword here is "scope". You should learn about this concept.

Development / Re: Music transitions (Fading in/out)
« on: June 09, 2018, 11:39:29 pm »
Exercise: code it yourself. (Hint: use timers to change the volume in a smooth way.)

Zelda Return of the Hylian SE / Re: Any news on Oni Link Begins SE?
« on: June 07, 2018, 08:52:10 pm »
And "Mercuris Chess XD2" was translated into English on April. It's the best mini-fangame of the team.

Zelda Return of the Hylian SE / Re: Any news on Oni Link Begins SE?
« on: June 07, 2018, 12:53:39 pm »
The team and collaborators are now working mainly on the engine and editor, shaders, new pixel art, a (secret) new website, and the projects "A Link to the Dream" and "Children of Solarus". The projects OLB-SE and Mercuris Chest are in pause mode for now.

How can I find the english version of XD2? Did I miss something?
I think so. I guess that the selected language was saved as French the first time you initialized the game, so I guess that you need to select the language again in the corresponding menu. Did you check the "options" menu to change the language? (Look for it somewhere in the game.)

EDIT: another way (a dirty way) to change the selected language is to open the file settings.dat in your savegame folder (it will be somewhere in your computer, and that folder depends on your OS), and then replace the line
Code: Lua
  1. language = "fr"
with this new line
Code: Lua
  1. language = "en"

EDIT 2: in the options menu, you can read above in French "press space to select language" (necessary to choose language). But since you don't know French, you didn't understand that and so you didn't know that you needed to press space (or maybe you didn't even read that line).

Your scripts / Re: Dodge/Dash/Roll Action
« on: June 04, 2018, 09:28:12 pm »
Exactly, you should use hero:get_ground_position() and not hero:get_position() if you do things in that way.
In any case, I will give a remark on the advantages/disadvantages of both approaches:

1) If you register that function in on_position_changed to check your dash state, as you did, that code will be called always (and many times unnecessarily) when the hero changes position. This may be faster than a timer, but it's also being called when you are not dashing, whenever you move the hero.

2) The second approach, with the timer, would only be used when you are dashing, and you can destroy the timer after the dash. If you think that calling the timer once per millisecond is not optimal, you can call the timer once each 10 milliseconds instead (but be careful, because the ground may change between 2 callbacks of the timer, although this is not a problem if you check the ground again when the dash has finished and independently of the timer). This approach is slower but only during the dash, the rest of the time your code is faster.

I don't think there is really a noticeable difference in speed between approaches 1) and 2). For instance, in my rain/snow/hail scripts, I am updating a screen-sized surface each 5 or 10 milliseconds (depending on the mode), and the game runs as fast as a lightning. The choice is just a matter of personal preference.

Your scripts / Re: Dodge/Dash/Roll Action
« on: June 03, 2018, 10:31:37 pm »
An important detail is that you should not use the normal position of the hero but the ground position.

Development / Re: how can you draw similarly to the light_manager
« on: June 01, 2018, 04:56:06 pm »
Yeah, I forgot option "3) Using blend modes."

It is not announced yet, but std::gregwar (who is developping shaders) made some experimental shaders allowing several dynamic light sources with shadows on the hero (and other entities). It works also with moving light sources, and looked awesomly awesome. Those shaders will be usable with Solarus v1.6 when he shares the code.

Development / Re: how can you draw similarly to the light_manager
« on: June 01, 2018, 03:04:19 pm »
1) With shaders, when Solarus v1.6 is released,
2) With a black surface that has a (semi)transparent circle in the middle.

Your scripts / Re: 8-bit Solarus Animated Logo Intro
« on: May 31, 2018, 08:36:28 pm »
This looks really charming!! I can't wait to test your game someday. :D

General discussion / Re: Quick Question about
« on: May 31, 2018, 05:06:08 pm »
Your musics are in the folder "musics/eduardo/", so
the id for your boss music is "eduardo/boss" and not just "boss". That will fix your problem. You can now destroy your link above.

General discussion / Re: Quick Question about
« on: May 31, 2018, 03:14:56 pm »
-I was wrong on something: the extension should not be written in the filename (according to the Lua API).

-We need more info to find the problem. This could even be an engine bug, but that's unlikely to be the case, so I want to be sure before we open an issue. Questions:
1) Which version of Solarus are you using?
2) Is that file added as a quest file in the Quest Editor?
3) Which is the extension of the file? (Some audio extensions are not supported by Solarus)
4) Is that music being played when attached to a map in the map editor?

It would also help a lot if you can temporarily share a link to your folder, so that we can help you solve this problem.

Pages: [1] 2 3 ... 64