Recent Posts

Pages: [1] 2 3 ... 10
1
This content is simply exciting and creative. I have been deciding on a institutional move and this has helped me with one aspect Superhero Leather Jacket
2
Game art & music / Re: Legend Of Zelda Link's Awakening tile set
« Last post by suffixdreadful on June 18, 2022, 06:21:33 AM »
The old and aging animatronics are joined by a new cast of characters
3
Development / How to buy items
« Last post by CopperKatana on June 13, 2022, 02:02:59 AM »
Hello, I am trying to program a shop in my game. But I think I'm not quite understanding  how to implement buying things. I watched the official tutorial on Shops and there was a dialog called _shops.question, which says something like:

Price is $v rupees.
$? Buy
$? Don't Buy

And the engine should fill in the item's price in the $v part, and recognize the "Buy/Don't Buy" part as selectable options. While the price of the item is properly displayed in my game, these options are just displayed as text with the $? symbols. The engine does not recognize them as choices.
How can I make it so that these are choices, and how do I control what effect each choice has?
4
General discussion / My new YouTube channel, 100% fangames content
« Last post by Zeldo on June 04, 2022, 09:49:04 AM »
Hello everybody :)

I created a new YouTube channel ! It's ZeldoGames and you'll find some fangames content and my personnal creations on it.
Here's the link to the channel: https://www.youtube.com/channel/UCogiQaYMY_EvxR0TCUsxgbw

The videos are in French but I added English subtitles for you ;)

Thank you :D
5
Hopefully that helps if you haven't already fixed it.  :D

Nope, I never fixed it.  I've been addressing other aspects of the project while waiting for potential feedback/input about this.

Anyway, I've found a workaround that will hopefully do what you want:

Change the line:

Code: [Select]
function jumper_found():to
Code: [Select]
function jumper_found(self, object):
self will be the custom_entity, and object will be the same as your object variable - you won't need to assign it, just delete the 'object = get_facing_entity()' line.

I worked this out from reading the docs on set_can_traverse, it mentions that the function you assign can take 2 parameters, the entity and the one you're colliding with.

Hopefully that helps if you haven't already fixed it.  :D

Thanks for the workaround!  This method seems to be working.  I will know for sure once I start adding other interactions for other entity types using a similar method.
6
Hopefully you've fixed this already, but I've had a look and I'm getting the same problem with get_facing_entity just returning the same entity each time.

I'm just a beginner with Solarus but it definitely looks like a bug?

However, when my custom entity collides with a chest, my function isn't triggering, only jumpers - so that might be a problem with part of your code that isn't shown.

You might want to post the problem with get_facing_entity on the gitlab as an Issue, I don't expect that to happen.

Anyway, I've found a workaround that will hopefully do what you want:

Change the line:

Code: [Select]
function jumper_found():to
Code: [Select]
function jumper_found(self, object):
self will be the custom_entity, and object will be the same as your object variable - you won't need to assign it, just delete the 'object = get_facing_entity()' line.

I worked this out from reading the docs on set_can_traverse, it mentions that the function you assign can take 2 parameters, the entity and the one you're colliding with.

Hopefully that helps if you haven't already fixed it.  :D
7
Game art & music / Re: Legend Of Zelda Link's Awakening tile set
« Last post by delisafrick on May 20, 2022, 10:47:49 AM »
The external link doesn't work.
8
This may be user error and not a bug because I am not a programmer by trade or experience.  Apologies in advance.

I have a side project in which I am having a problem where "get_facing_entity()" only works once.  In the project I have a custom entity that follows the hero around.  This custom entity needs to be able to detect certain map entities, namely movement entities like "stairs" and "jumpers."  The relevant code is below:

Code: [Select]
--ALLOWING THE CUSTOM_ENTITY TO INTERACT WITH "JUMPER" ENTITIES
custom_entity:set_can_traverse("jumper", jumper_found)

--FUNCTION SETUPS

--TO END ANY CURRENT MOVEMENTS IF APPLICABLE
function end_movement()
  custom_entity:stop_movement()
  alt_movement = false
  object = nil
end

--ACTIVATES WHEN THE CUSTOM_ENTITY RUNS INTO A "JUMPER"
function jumper_found()
    --ENDS ANY MOVEMENT
    end_movement()

    --ASSIGNS THE ENCOUNTERED "JUMPER" SO I CAN PULL PROPERTIES FROM IT
    object = custom_entity:get_facing_entity()

    --CREATES THE JUMP MOVEMENT
    jump = sol.movement.create("jump")

    jump:set_ignore_obstacles(true)

    --PULLS A CUSTOM "DIR" PROPERTY WHICH TELLS THE CUSTOM ENTITY WHICH WAY TO JUMP
    jump:set_direction8(object:get_property("dir"))

    --PULLS A CUSTOM "DIST" PROPERTY WHICH TELLS THE CUSTOM ENTITY HOW FAR TO JUMP
    jump:set_distance(object:get_property("dist"))

    --STARTS THE JUMP AND ENDS THE JUMP SO STANDARD MOVEMENT CAN RESUME
    jump:start(custom_entity, end_movement)
   
    --CUSTOM VARIABLE USED ELSEWHERE TO PREVENT STANDARD MOVEMENTS FROM ACTIVATING WHILE JUMPING
    alt_movement = true
end

--RUNTIME MONITORING
function custom_entity:on_update()

  print(object)

end

The problem is that "get_facing_entity()" will only work on the first entity it encounters.  For instance, I have a "chest" entity and a "jumper" entity; if I bump the custom entity into the "jumper," then "get_facing_entity()" assigns that entity to "object."  I can manually set "object" back to "nil" using a debug key command, but if I proceed to bump the custom entity into the "chest," then "get_facing_entity()" still returns the id of the "jumper" that it touched earlier, and the "jump" movement will activate.

What's even more strange is if I bump into the "chest" first, then the "chest" entity is assigned to "object" even though according to my understanding of the above code, my custom "jumper_found()" function should only be activating when the custom entity explicitly encounters a "jumper" entity.

I've moved my "jumper_found()" function declaration into the "on_created()" function to ensure it doesn't run unless called.  No change.

I've attempted making "object" local.  No change.

I've attempted embedding "get_facing_entity()" into the "on_update()" function so it constantly runs.  No change.

I'm sure I am probably just using "get_facing_entity()" wrong, but I've been stumped for 3 days now on this one task.
9
Your projects / Re: First Practice Project Ready to Play!
« Last post by Zeldo on May 16, 2022, 01:43:11 AM »
I was just wondering how lonk it took you to do this little game ? It was fun for sure !
But I guess the end is when you have de tunic right ?

Continue the good work :D
10
Your projects / Re: Le Défi de Zeldo - Chapitre 2: La Tour des Souvenirs
« Last post by Zeldo on May 16, 2022, 01:22:49 AM »
Hello everybody !

After a while and a serious reflexion about my creator work, I'm coming back with more fangame projects !

Here comes the NEW VERSION 1.1 of the game !

These update brings some new features like:
- A Fast Travel System
- The option to activate or not de Link's voice in game
- An enhanced music quality
- A remapping of the Forest and the leafes labyrinth, more clear now
- Some graphical effects added
- Some bugfixs
- And more !

This new version of the game is available here:
https://github.com/ZeldoRetro/defi_zeldo_chap_2/releases/tag/v1.1.0

For the people who already played the game and completed it, I added some new content ! However, only the true completionists will be rewarded by it !

Have fun playing the 1.1 version !
Pages: [1] 2 3 ... 10