Menu

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.

Show posts Menu

Messages - PeterB

#16
Hi, for me the most obvious way to solve this would be to split the map into smaller areas and use side of map transporters to link them together  :)
#17
Hi,

I have had a look at the source code and it is the vase.dat file that is your problem

As you can see from the attached image it is looking for the vase_broken.png when you destroy it.

To fix it you can go into the sprite in the folder view in the editor and choose another 8 frame image to use for the broken vase image.

Perhaps use the stone.png and use the brown sequence.

#18
Development / Re: Help with name display code
January 08, 2020, 05:02:22 PM
Ok, brilliant thanks, thanks for the discord tip too.
#19
Development / Re: Help with name display code
January 05, 2020, 10:47:49 PM
Hey Llamazing,

Struggling with the - EMPTY - name if no save game present section. Any help gladly received as I am pulling my hair out with this one today. It doesn't seem to want to run the two lines                 local name = "- " .. sol.language.get_string("savegames_menu.empty") .. " -"
player_name_text:set_text(name)


For some reason!!! Here is the full section.

-- Reads the existing savegames and creates the savegames surfaces.
local function read_savegames()

  for i = 1, 3 do
    local file_name = get_savegame_file_name(i)
    local surface = sol.surface.create(272, 16)
    surface:set_xy(24, 8 + i * 48)
    savegames_surfaces[i] = surface

player_name_text = sol.text_surface.create{
      font = "alttp",
      font_size = 11,
    }

    if not sol.game.exists(file_name) then
      games[i] = nil
    else
      -- Existing file.
local game = game_manager:create(file_name)
games[i] = game

-- Player name get or use EMPTY
if sol.game.exists(file_name) then
player_name_text:set_text(game:get_value("player_name"))
else
                local name = "- " .. sol.language.get_string("savegames_menu.empty") .. " -"
player_name_text:set_text(name)
end
    -- Draw hearts and player name.
draw_hearts(game, surface)
player_name_text:draw(surface, 64, 8)
    end
  end
end 


full lua file and screen capture attached, shame you can't see the fairy's wings moving though. Thanks for any help.

#20
Development / Re: Help with name display code
January 05, 2020, 10:47:19 AM
Brilliant thanks Llamazing, i hadn't even thought about that. I thought it was probably that line, but as there weren't any errors i got sidetracked on font colours.

It all works now, i used

player_name_text:draw(surface, 64, 8)

which works a treat. Now on to the - Empty - file name problem!!!
#21
Development / Help with name display code
January 04, 2020, 09:20:50 PM
Hey guys,

I am after some help with my savegames.lua. I am trying to get the players name from the save1.dat file (or 2 or 3) and print it on the game select screen.

I can't see what I am doing wrong with drawing it on the screen, so am after some help please.

Here is the relevant section of code, and I have attached the savegames.lua file.

Thanks in advance.

Peter

local function read_savegames()

  for i = 1, 3 do
    local file_name = get_savegame_file_name(i)
    local surface = sol.surface.create(272, 16)
    surface:set_xy(24, 8 + i * 48)
    savegames_surfaces[i] = surface

player_name_text = sol.text_surface.create{
      font = "alttp",
      font_size = 11,
    }

    if not sol.game.exists(file_name) then
      games[i] = nil
  local name = "- " .. sol.language.get_string("savegames_menu.empty") .. " -"
      player_name_text:set_text(name)
    else
      -- Existing file.
    local game = game_manager:create(file_name)
    games[i] = game

-- Player name get and display
player_name_text:set_text(game:get_value("player_name"))
player_name_text:draw(surface, 90, 16 + i * 48)

    -- Hearts.
    draw_hearts(game, surface)
    end
  end
end
#22
Ok thanks llamazing. Sounds like a bit to much trouble for me as I have over 300 maps in my game.

Perhaps i wont be doing this anytime soon and will stick to my large ffomega tileset!
#23
Ok, thanks for the reply. I am struggling to figure out what to put in for "quest_path map_file_1.dat"?

Is quest_path where my data folder is or where my maps folder is??

And do i need to input every map file name here instead of "map_file_1.dat"??

Sorry, just starting on my lua learning journey.
#24
Hi, does anyone know how to use the update tileset script?

I tried putting the script in the ../data/scripts folder and calling it from the game_manager script but i am getting the below error.

Any ideas, as i can't find any documentation on how to use it?

Error: In on_started: scripts/update_maps_to_rearranged_outside_tilesets.lua:26: attempt to concatenate global 'file_path' (a nil value)
stack traceback:
[C]: in function '__concat'
scripts/update_maps_to_rearranged_outside_tilesets.lua:26: in function 'get_pattern_mapping'
scripts/update_maps_to_rearranged_outside_tilesets.lua:107: in main chunk
[C]: in function 'require'
scripts/game_manager.lua:10: in main chunk
[C]: in function 'require'
scripts/menus/savegames.lua:4: in main chunk
[C]: in function 'require'
main.lua:20: in function <main.lua:9>
#25
Game art & music / Re: ALTTP font
August 07, 2019, 11:38:20 PM
Brilliant, thanks.
#26
Game art & music / ALTTP font
August 01, 2019, 11:13:51 PM
Guys,

In case anyone wants the arrows for the signs in the Link to the past font, here is one i have just done.

It uses " for the up arrow, # for the down arrow and [] for the left and right arrows.

Thanks,
#27
Hi does anyone know which lava tiles go behind the mini volcanoes?

The first image is the original, and the second my attempt, using the tiles in the third image.

Or is there some sort of tile that goes over the top to mask the bits around the edges???

I keep looking through the tile set but can't seem to replicate the original!!!
#28
Bugs & Feature requests / Re: Sound Error
June 08, 2019, 10:23:57 PM
Obvious question, what have you changed since it last worked properly?
#29
Hey 20degree,

Great start and nice graphics.

One thought from me, it may also be useful to base the chapters on Christopho's Youtube tutorials although you may want to change the order or expand them as you see fit.

He does also mention a lot of little nuggets of brilliant information when doing these. e.g. the Doors tutorial (32) where he mentions using dynamic tiles to hide doors and the easy way to remove them.

I use this for bomb walls rather than script them, and this could easily be added in the chapter on doors.

I also agree with Max, it may be easier on the eye if you lose the Solarus background.

Thanks,
#30
Development / Re: Quest document - updated pdf
April 23, 2019, 10:45:16 PM
Brilliant thanks Christopho,

I really find it helpful to have a searchable pdf.

It makes it so much easier trying to find specific things in the document.