SAR_MVAchievements version 1.2.1

Discussion in 'JS Plugin Releases (RMMV)' started by Sarlecc, Apr 20, 2016.

  1. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV


    SAR_MVAchievements version 1.2.1

    Sarlecc



     
    Introduction
    This plugin allows you to have achievements inside an RPG maker MV game. It is highly flexible allowing you to program your own achievement scene or to use one of the achievement scene style plugins I have provided.
     
    Features
    - Global achievements
    - Non-global achievements
    - Achievement auto checking
    - Achievement sealing (disallows extra achievements from being added over what you want)
    - Tie achievements to switches or variables
     
    Screenshots

    [​IMG][​IMG]  [​IMG]


     
    How to Use


    *Note* old saves will not work with this script you will have to make a new game.



    Script calls:
    SAR.achievements.achievementSwitch(global, name, description, gameSwitchID, reward, icon, bool)
    global = number 1 or 0
    name = string
    description = string
    gameSwitchID = number
    reward = Common Event ID
    icon = number
    bool = optional true or false (false is default)


    SAR.achievements.achievementVariable(global, name, description, gameVariableID, limit, reward, icon, bool)
    global = number 1 or 0
    name = string
    description = string
    gameVariableID = number
    limit = number (this is what the gameVariable must equal to recieve the achievement)
    reward = Common Event ID
    icon = number
    bool = optional true or false (false is default)


    Plugin commands:
    SarleccAchievementsSwitch global name description gameVariableID limit reward


    SarleccAchievementsVariable global name description gameVariableID limit reward


    *Note that the description value uses periods "." to bind words to its self. i.e: this.is.a.description
     
    Demo
    Included in the commercial licensed version
     
    Script
    Non-Commercial links.
    Github link: SAR_MVAchievements.js
    Github link: Achievement_scene_style1.js



    For commercial use license:
    Shop $5.99


    Comes with the following bonus':
    Demo, pdf manual, SAR_POPUP, an additional achievement scene style, a plugin that displays particle explosions, and js-expression-eval (for convenience as SAR_POPUP uses it). It also includes some basic graphics (shown above in the screen shots) and a sound effect.


     
    FAQ
    None yet.


    UPDATES

    SAR_MVAchievements 1.1.0:
     *       changed the reward variable to be a common event id


    SAR_MVAchevements 1.2.0:


    * Fixed global achieves not being so global. Fixed anyGlobalAchieves switch now the id you use 
    * will work for it.


    SAR_MVAchievements 1.2.1:


    * Fixed the normal achievements from acting like global achievements (hopefully).


    SAR_AchievementPOPUP 1.5.0:
     *       can now set the location
     *       can now have the popup at the top or bottom of screen
     *       popup will fadein/out when at top or bottom of screen
     *       can set size of popup
     *       can set the background of popup
     *       to have a new line in popup use a \n after the name of the achievement


    SAR_AchievementPOPUP 1.5.1


    *        1.5.1 fixed this.positionType to this._positionType where I forgot an underscore on line 259
    *       removed some console.log lines


    SAR_AchievementPOPUP 1.5.2:
    *       fixed glitch with the popup displaying more than once when clicking with the mouse


    SAR_Explosion 1.1.0:
    *       1.1.0 Rewritten to work with RPGMaker MV version 1.3.1
    *       will no longer work with old versions of MV.


    OTHER:
    GameOver image is now a .png
    please remove the old .pdn file.


    updated the manual


     
    Credit and Thanks
    Non-commercial credit: Sarlecc


    Commercial licensed credit: Sarlecc, Matthew Crumley, Chad Engler


    TERMS
    link
     
    Author's Notes
    Next on my list to do now that I know how JS works is Time_Machine and Skill_Usage.
     
    Last edited by a moderator: Jan 28, 2017
    #1
    DangDut, Val and JiM83 like this.
  2. lawina

    lawina Veteran Veteran

    Messages:
    147
    Likes Received:
    28
    First Language:
    English
    Edit #2: I'm getting a lot of errors running your plugin in RPG Maker MV 1.3.1 (latest update).


    Here's one: SpriteBatch does not exist anymore, please use the new ParticleContainer instead.
     
    Last edited by a moderator: Sep 12, 2016
    #2
  3. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV
    Thank you for letting me know on this. I haven't had time yet to update to 1.3.1 so I haven't tested it yet. I will let you know when I get it updated.


    I'm assuming that this is being caused by the particle explosion script? Does it work without this one or does it give different errors?
     
    #3
  4. lawina

    lawina Veteran Veteran

    Messages:
    147
    Likes Received:
    28
    First Language:
    English


    Thank you for the quick reply! Everything looks better when the particle explosion plugin is disabled. I'm still in the progress of setting it up however, and will let you know if I come across any other issues. Is there any way to change the popup script by the way? Like remove the popup border (so it appears more like a dim message box), and change the size and location where it pops up? I'm trying to make it so it fades in and fades out up at the top center of the screen.


    PS: It's probably because I use 1296x768 screen resolution that the popup looks so weird right now.
     
    Last edited by a moderator: Sep 12, 2016
    #4
  5. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV
    Strangely I could have sworn I added functionality to change the location of the popup (as I was testing it when I was designing this plugin). Well I'll make sure it gets added back in.


    You're wanting the popup to fade in/out (vs slide left) from the top of the screen am I correct? Should be able to add this functionality (little bit different than the above as that only allows bottom, center and top of the right side of the screen).


    I can look into allowing size changing of the popup.


    Same with the popup background.


    Also the error is fixed with SAR_Explosion.js now just having trouble with uploading the change (slow internet) :| .


    If it's okay with you I'll add the above additions to it before I upload (that way I wont have to upload twice).
     
    #5
  6. lawina

    lawina Veteran Veteran

    Messages:
    147
    Likes Received:
    28
    First Language:
    English


    Yes, that'd be perfect! Thanks a lot for the quick support.
     
    #6
  7. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV
    Plugins should be updated (please inform me if you have trouble downloading the new version or have more bugs that show up).
     
    #7
  8. lawina

    lawina Veteran Veteran

    Messages:
    147
    Likes Received:
    28
    First Language:
    English
    Hi Sarlecc! I missed your message. Great job with the changes. It works perfectly now.
     
    #8
    Sarlecc likes this.
  9. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV
    Updates:


    Non_commercial and commercial:


    SAR_MVAchievements reward variable is now a common event id will run a common event when larger than 0.


    Commercial only:


    SAR_AchievementPOPUP fixed a glitch with the popup showing multiple times when the left mouse button was clicked.


    Manual has been updated to reflect the changes to the reward variable. Along with a small note stating that the SAR_Explosion Plugin must be enabled in order for the Popup to play a sound effect.


    Please let me know if any more bugs appear so they can be squashed promptly.
     
    #9
  10. SimProse

    SimProse Veteran Veteran

    Messages:
    359
    Likes Received:
    191
    Location:
    United States
    First Language:
    English
    I've PM'ed you. Script does look awesome.
     
    #10
    Sarlecc likes this.
  11. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV
    Updated the SAR_MVAchievements plugin to 1.2.0: Fixed global achieves not being so global. Fixed anyGlobalAchieves switch now the id you use will work for it.


    Let me know if any bugs show up with the new version!


    Edit So I have been alerted that my latest fix introduced a new bug that is preserving the state for non global achievements I am currently working on a fix. Should be fixed now.
     
    Last edited by a moderator: Jan 28, 2017
    #11
  12. Fernyfer775

    Fernyfer775 Veteran Veteran

    Messages:
    1,287
    Likes Received:
    769
    First Language:
    English
    Does this allow you to attach "rewards" to the achievements?
     
    #12
  13. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV
    Yes rewards are made in a common event and when setting up your achievement you will use the id of the common event.


    So:


    SAR.achievements.achievementSwitch(global, name, description, gameSwitchID, reward, icon, bool)


    becomes something like the following:


    SAR.achievements.achievementSwitch(false, "my first achievement", "its my first" , 3, 1, 0, false)


    This will run the common event with id 1 once the achievement has been obtained.


    Edit: fixed the normal achievements from acting like global achievements please let me know if you encounter anymore bugs.
     
    Last edited by a moderator: Jan 28, 2017
    #13
    Fernyfer775 likes this.
  14. CloudzChow

    CloudzChow Villager Member

    Messages:
    5
    Likes Received:
    1
    First Language:
    Indonesia
    #14
  15. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV
    Hey thanks for the mentioning this! I am assuming it is due to the latest MV update. Anyway I will start working on getting it fixed ASAP (it may take a little while though as real life has been very busy lately).

    Edit: In the mean time you can view the help at the top of each by opening up the .js file in a text or code editor. I will also have to check params though (as I believe these got changed too).

    Edit2: I just tested in the latest MV 1.5.0 with the file from GitHub and it looks like it is all there. Could you please send me your SAR_MVAchievements.js file in a PM so I can check that one?
     
    Last edited: Aug 3, 2017
    #15
  16. CloudzChow

    CloudzChow Villager Member

    Messages:
    5
    Likes Received:
    1
    First Language:
    Indonesia
    Hmmm...I see, maybe I'm still using the older version of it, I might update it later and see the differences
     
    #16
  17. UltraMario12

    UltraMario12 Villager Member

    Messages:
    14
    Likes Received:
    0
    First Language:
    German
    How do you make a Acievement that goes over all playthroughs.
    In my game, everytime you die the Variable goes +1 but everytime you start a new game the variable is at 0. So you can not get the Acievement for 100 Dies...

    If this is not possible i will remove the plugin from my project...
    I really want a Acievement system but if it didn't work... meh....
    I'am trying now for 6 hours and don't get it working...
     
    Last edited: Jul 16, 2018
    #17
  18. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV
    Plugin command method:
    SarleccAchievementsVariable global name description gameVariableID limit reward
    SarleccAchievementsVariable 1 Deaths Die.100.times 5 100 3
    Strangely I must have forgot to program in the icon and bool values for plugin commands.

    SAR.achievements.achievementVariable(global, name, description, gameVariableID, limit, reward, icon, bool)
    SAR.achievements.achievementVariable(1, "Deaths", "Die 100 times", 5, 100, 3, 2)
    bool is only needed if you want to start a game with the achievement its kinda like one of my debugging tools I just left in.


    Now whats suppose to happen is when ever you save the game all global achievements get saved in their own save file. These then get loaded upon creating a new game or loading up a different save file.

    Anyway hope this helps I haven't actually done any programming for awhile now due to life issues so I might be a bit rusty.

    Edit: Also there is a possibility that the plugin might not work with current versions of MV as I have not personally tried it in about 6+ months. So I do not know if anything my script uses has changed.
     
    Last edited: Jul 16, 2018
    #18
  19. UltraMario12

    UltraMario12 Villager Member

    Messages:
    14
    Likes Received:
    0
    First Language:
    German
    But in my game you are not able to save. So it would be nice if the plugin saves on its own without using a save file. Because the player should not be able to load any files. In the menu he only should be able to click on New Game or Acievements.
     
    #19
  20. Sarlecc

    Sarlecc Veteran Veteran

    Messages:
    454
    Likes Received:
    209
    First Language:
    English
    Primarily Uses:
    RMMV
    okay in that case try this:
    DataManager.saveAchievesWithoutRescue(21)
    Need to call this at various times to save achievement data (like before game ends when dying for example) would probably also work well when changing maps.
     
    #20

Share This Page