Preparing a Vis. project... (Catyph)

  • #30, by Simon_ASATuesday, 21. January 2014, 10:35 11 years ago
    Ok great, thanks ! I thought this problem was solved in your template, and that I could get inspiration wink No problem, I'll try quicksaves + lua.

    My guess is that an improved save system would be more than welcome in a future version of VS. Having the possibility to choose the slot where to save sounds like a basic necessity.

    Another thing that would be welcome is a "scale option" on the layers. Instead of writing the lua code to resize an animation, it seems better for beginners to have a scale button where you can choose the size. Scaling an animation is very useful, I used it several times already to save memory.

    Great Poster

    321 Posts


  • #31, by afrlmeTuesday, 21. January 2014, 12:33 11 years ago
    currently scale animation only works on active animations. it is a good idea though - at least for people unwilling to/having difficulty in learning Lua script.

    Imperator

    7278 Posts

  • #32, by Simon_ASATuesday, 21. January 2014, 23:36 11 years ago
    So until now the Savegame system is still giving me headaches ^^

    I have successfully used the quicksave feature to save/load a slot #1, 2, 3... It works well.
    The difficulty is to save the screenshot and display it.

    To save a screenshot, I'm using the instructions from the wiki here :
    https://www.visionaire-studio.net/wiki/article/createscreens...
    and http://wiki.visionaire-tracker.net/wiki/CreateScreenshot
    There's something I must do wrong, because my screenshot folder stays empty.
    I have also checked in the Username/AppData/Local/ Save folder, and I have the bookmarkx.dat, but no png
    Any ideas ? I am running VS in admin, and the name of the game in the properties is the same than the name of the .ved
    There's probably something where I'm mistaken with the code entry.

    And then, if I successfully create the screenshot, what is the code todisplay the picture ?
    maybe : loadfile ([filename]) ???
    Should I load it in a savegame area ? I'm a bit confused.

    I'm sorry to ask all the time :S
    As soon as my savegame system will be created, i'm sure I won't need so much help.

    Great Poster

    321 Posts

  • #33, by afrlmeWednesday, 22. January 2014, 01:08 11 years ago
    to create a screenshot: add the code into a execute a script action part. the screenshot folder should be created in the same folder where your project .ved file is located. the screenshot folder needs to exist for it to create & save/export a screenshot. you should create a separate script for each...
    createScreenshot("screenshots/save_1.png")
    


    I'm not sure off the top of my head on how to import the screenshot images & display them... that part was mostly theoretical thoughts & I don't know if it is possible or not, but I will look into it when I can.

    If we could do this, then it would be nice as we could also create option menus & save/load menus on in game interfaces without having to change to a menu scene.

    Imperator

    7278 Posts

  • #34, by Simon_ASAWednesday, 22. January 2014, 12:10 11 years ago
    Ok thanks a lot ! I have the screenshots creation working.

    I had written
    createScreenshot("screenshots/savegame_x.png")
    


    --> I thought the x would be automatically implemented into a new number by the other script (this one)

    Now,
    is there a code to rename a picture (or file) that has already been created in the screenshots folder ?
    Found this in LUA : os.rename (oldname, newname)

    os.rename ("screenshots/save_1.png", "screenshots/save_2.png")
    

    It should rename save_1.png into save_2.png, right ? or is there something specific in VS ? I'll give it a try.
    If it works I'll explain what I want to do.

    Great Poster

    321 Posts

  • #35, by afrlmeWednesday, 22. January 2014, 13:21 11 years ago
    the old scripts in the community wiki are outdated versions... in the end it made more sense to just have it print the date/time to the screenshot which prevents it from overwriting previous screenshots.

    why would you want to rename a screenshot?

    Imperator

    7278 Posts

  • #36, by Simon_ASAWednesday, 22. January 2014, 14:59 11 years ago
    the old scripts in the community wiki are outdated versions...

    I didn't find the "os.rename" code in the old wiki, but in the LUA 5.1 reference manual.
    The problem is that I just can't find the answers I'm looking for. I'm willing to create my game by myself but I can't, and it is frustrating. I think all the infos about VS are dispatched here and there on too many different pages, and it really misses a better organisation in the wiki to make things clear for beginners. Maybe you [not "you = Afrlme", but "you = the VS team"] should get inspiration from the Adventure Maker support /My own opinion.

    Why would you want to rename a screenshot?

    (The os.rename code works, I tried. So why not using it ?)
    I'm trying to find by myself how to make my own Save Menu, without bothering you everytime I have a question. The tutorial by GlenFx is good, but as explained before I want the player to choose the slot where to save (and not saving in the first available slot). As a result I can't use the Save function, and I have to use the Autosave (quicksave). And so, everything has to be built manually (create and display screenshot in the slot, with date and time).
    Maybe it's easy or obvious for several people here to create a quicksave menu with thumbnails, but not for me. So I have to try and experiment various things ! This is the main reason why I want to rename a screenshot.

    Now, explanations :
    - My main idea is to create a single screenshot "save_1.png" once, everytime I load my Save Menu with F1.
    - Then in the save menu, I want to display another picture called "slot1.png" in the slot 1, a "slot2.png" in the slot2, etc... I want each picture to be in the good slot
    - The first time you play, when there's no savegame at all, the slotx.png is a blank picture. Then it is replaced by the save_1.png
    --> So my idea is to rename the created "save_1".png into "slotx.png" if I want to display it in slot x.
    Don't know if it's clear...

    Great Poster

    321 Posts

  • #37, by afrlmeWednesday, 22. January 2014, 16:07 11 years ago
    I didn't find the "os.rename" code in the old wiki, but in the LUA 5.1 reference manual.


    I never said anything about the os.rename() function - I was referring to the createScreenshot example code. I wrote it ages ago.

    The problem is that I just can't find the answers I'm looking for. I'm willing to create my game by myself but I can't, and it is frustrating.


    I appreciate that you are willing to try & figure things out on your own, but myself, the vs team & the rest of the community are here to help; if we can.

    I think all the infos about VS are dispatched here and there on too many different pages, and it really misses a better organisation in the wiki to make things clear for beginners. Maybe you [not "you = Afrlme", but "you = the VS team"] should get inspiration from the Adventure Maker support /My own opinion.


    I am part of the VS team, albeit not one of the developers, but a part of the team since last year sometime. We do pretty much everything pro bono "gratis" & thus it is all down to finding the time & motivation necessary to work. I myself am working on providing an in depth guide to all things vs, - in layman terms - on the new wiki, but I'm working around my own stuff, at home, my own project, providing support on the forum as quickly as possible & helping other people out with their projects via advice or providing lua scripts for their games & so on...

    -- * --

    in regards to the os.rename() - you could just add the blank/default save slot images as part of the background or you could use if queries in Lua to see if the slot_x.png file exists for each slot & if not then display blank slot image but use an object with image instead of trying to import a screenshot version of the default slot image.

    Imperator

    7278 Posts

  • #38, by Simon_ASAWednesday, 22. January 2014, 17:06 11 years ago
    Ok, thanks for putting things clear. Please don't get mad ! There's probably a misunderstanding between french to german translation through english.

    I didn't want to sound rude or totally frustrated and angry. It seems that you somehow took it personally, while I was explaining a global point of view (which is why I was talking of the whole VS team - you being part of it or not). I understand that helping people on the forums is time consuming. I believe that most indie developers understand that ! I myself work 7days/7 since 5 years now. So yes, I understand ! Peace ! grin

    I never said anything about the os.rename() function - I was referring to the createScreenshot example code. I wrote it ages ago.

    This is exactly what I wanted to explain before. So I'll try to explain it differently : yes, the wiki exists, but it seems to me that there are things mixed up. I found what you call the "old script" in the wiki, by clicking on "wiki" at the top ot this page. I didn't look for it in any old pages, or if I did, it was not on purpose.

    For someone who just starts with VS (like me), there are too many different informations everywhere that would need to be listed differently, because some important informations are lost in the middle of advanced stuff (It's not a reproach but an observation).
    I know it is taking a lot of time to create a wiki and keep it up to date, so it's not a judgement !
    You're doing a great job on the forums : didn't I thank you again and again from the beginning ? smile See, I'm happy !

    -------
    Ok so I'll have a look again on how I can load the screenshot to display it in the good slot.
    Thanks

    Great Poster

    321 Posts

  • #39, by afrlmeWednesday, 22. January 2014, 17:53 11 years ago
    No mate, I didn't take anything personally. it's just how I come across & your English is perfectly fine. wink

    The wiki via the menu up top is the community/forum wiki - we don't really use that much these days & thus like the old 2d wiki, it is somewhat antiquated. I mostly used the community forum for posting Lua script examples & yeah a lot of them are somewhat complicated.

    The plan is that on the new wiki we will cover everything in great detail from setting up your game to what each action part & option etc does as well as cover an introductory guide to Lua Scripting, as well as VS exclusive Lua commands & much more. All the pages will eventually be compiled & linked inside of a single index page split into categories to make it easier to find what you are looking for. Also we have added a language template so anyone willing to translate the pages into other languages only need ask myself or one of the other team members to set up an account with write permission; when the English wiki is finished, of course.

    P.S: I am English. The rest of the team are German & Austrian but both Alex & Simon speak really good English, & David & Thomas' English isn't too bad & is improving all the time.

    Imperator

    7278 Posts

  • #40, by Simon_ASAWednesday, 22. January 2014, 19:13 11 years ago
    Can't wait to discover the new wiki then !
    Thanks for the details.

    By the way, I just released the short film introducing the world of my game Catyph :
    http://vimeo.com/84080449
    Hope some people like it here !
    A shame that I didn't find a german person to translate the subtitles razz

    Great Poster

    321 Posts