edited August 2016 in General Discussion
Hi everyone,

Ever since I first got into ORK, I admit that I might have almost quit because of its complexity and lack of understanding. However till almost a year, I came back and fiddle with ORK again. Needless to say, I almost quit again and thankfully didn't when there is a game to work on.

The more I work on it, the more I see at how straightforward it is to make plugins for compared to other assets I have worked with. Once I get past the learning curve, here's the current progress of it:
https://drive.google.com/file/d/0B2EOCdhyXGhwQkFkcEN5cVNMT2s/view?usp=sharing

An Achievement system with its own EventSteps. Sure, you can do it with Global Events/Game Variables but I prefer a more 'manage-able' solution.

Conclusion: things do work out if you put the time for it as learning and making it took me almost a whole day, surprisingly.

Download Link:
https://drive.google.com/file/d/0B2EOCdhyXGhwd0hENDJzZ2lQRjQ/view?usp=sharing

Note: There are two files: DLL and Source folder. You only need the DLL file. The Source folder is for adding modifications.

Setup
DLL Name : LynToolbox
Namespace: Achievements
Post edited by Raiulyn on
  • That looks really useful, Raiulyn. Could you do a tutorial on making it or share the code?
  • Nice! Eventually I hope to add Steam achievements myself, but in-game achievements are also really cool. Are you implementing an in-game menu where you can browse through them?
    Tactics RPG Grid Battle System for ORK
    ---------------------------------------
    Personal Twitter: https://twitter.com/AMO_Crate
    I make RFI! https://twitter.com/NootboxGames
  • @Catacomber Thanks! I'll share the code and put up a tutorial of sorts on how to use it. Still polishing up till it meets my standards.

    @Kirb Actually that's kinda what I had in mind when making this. The goal I'm aiming for is to create in-game achievements as painless as possible while being able to provide integration with other things like Steam achievements. Instead of an in-game menu, I'm looking into getting data from text codes(ex. #AchievementX#) so you create your own unique menus or put it in HUDs if you want.

    The problem with the text codes idea is that I might have to modify the source which could interfere other plugins using it. That and I'm currently stuck at 'how text codes grab the intended data' part. Hopefully, @gamingislove sheds some light on this.
  • It'd probably a lot easier using Log Texts for the actual achievements. That way you'd already have the full ORK integration with menu screens, event system and text codes :)
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • From what I remember of Steam's Achievement API (granted this is from a few years ago so it could be a wee bit outdated), this looks like it's going to be super easy to integrate. I think you just need a field for each achievement to store the ugly api name (like ACH_CH_1_TUTORIAL), unless you were going to type that in by hand during the Set Achievement Step? Is the use Value field for the stats-driven achievements?
    My little chunk of the internet: http://artemic.com
  • @gamingislove Not the answer I was hoping for but thanks for replying. I've found a workaround for the problem through Game Variables.

    @Firrerreo If that's the case, then Steam integration will be easy indeed. I would separate the plugin into different 'states' to choose from. Ex. 'Default State' handles in-game achievements and 'Steam State' handles steam achievements. So changing in-game achievements to steam achievements would be seamless and less hassle in maintaining code. Yes, the use Value field is for defining a threshold as requirement for achievement.

    Here's the explanation for each of the Achievement Steps:
    Check Achievement - Check if Achievement is completed
    Get Achievement - Grants the Achievement
    Set Progress Value - Sets the value of progress towards the Achievement
    Check Progress Value - Check if value has passed the Achievement requirement
  • @Raiulyn--the code and a tutorial would be wonderful. Thanks!
  • Awesome, thanks for the rundown of the steps, that looks like a solid wrapper for the api.

    And like @Cat, I would also happily love to see your code when you're ready. My own achievement "implementation" is still a bunch of big ugly empty functions for the most part. They're call placed inline in the game as needed, but yeah...hadn't gotten around to actually doing any real api wrapping yet. :)

    My little chunk of the internet: http://artemic.com
  • I'm at the part of saving and loading achievement from save files. For the life of me, I can't figure what BaseData's GetData() and SetData(DataObject) do. Is it for runtime or edito? or both? Anyone?
  • BaseData is the default implementation of the IBaseData interface, which is used for saving editor data. Usually, the default implementation should save all your public fields automatically, also all fields with custom classes (as long as they also implement IBaseData).

    For save games, it's the ISaveData interface, using SaveGame and LoadGame functions (but working the same as GetData and SetData of the IBaseData interface).

    If you want to save stuff with a save game, take a look at the custom save data system, or if you want to save stuff from a component on your player (or other group members), take alook at the custom component save data.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • edited April 2016
    The custom save data system implementation for Achievements is done. Savefiles should be able to save and load along with ingame achievements.

    I have added a Game Variables option for when you want to grab either status or progress data from or for debugging purposes. There's a better way to it (Refer to my question to GiL above) but it should do fine as a substitute for the time being.

    The zipped file should contain both dll and source. As for the source itself, I have commented where custom functions are to be placed at. I would do it myself but I don't have the APIs to test.

    Edit: It's ready. Download link at first post.
    Post edited by Raiulyn on
  • I have made the plugin and steps as simple and clear as possible. In case of a tutorial is needed, here is the quick setup I made:

    First, I set the 'Name' of the achievement and insert a game event for the 'Completion Event'. The event is just a 'Show Dialogue' node to display a notification box (Menus>GUI box) with 'no Auto Close button' and 'Closes after 3'. Add a Portrait to an Object Actor to show Achievement Image if you want. That's it for the Completion Event.
    Example: https://drive.google.com/file/d/0B2EOCdhyXGhwMGloZmcwMjRBN3M/view?usp=sharing

    Next, insert a 'Get Achievement' step to any event to unlock the Achievement. In my case, I added it into my SpawnPlayer Event in 'Menus>MainMenu>NewGameSettings>Start Event'. Of course I need something to show what achievements I have unlocked and did not so I add a quest showcasing the achievements as quest tasks and mark the quest task as complete. (Refer to http://orkframework.com/tutorial/howto/quest-system/)
    Example: https://drive.google.com/file/d/0B2EOCdhyXGhwV3ZZNjNPdmx6a2M/view?usp=sharing

    Like I said to Kirb, I find being able to make your own menu is a far flexible solution than making an ingame menu. As shown in the tutorial, a quest menu outlining achievements is one of the ways to do it. If you have a custom GUI box outside of ORKframework, use the 'GameVariables' option to pull status and progress data from.

    Tutorial done. I think I covered everything. I will chalk this up as [Release]/Complete if I don't see bugs for the next week or so. I would appreciate if you do bring up problems or any sorts.
  • Awesome, @Raiulyn. I have a busy week of meetings and deadlines ahead but I'll try to test it some.
    My little chunk of the internet: http://artemic.com
  • This sounds fantastic. Thanks so much. Will also try it this week.
  • edited April 2016
    Protip: don't lazily drag the contents of the entire zipped download into your Project like I did. Having the gameplay source code in there resulted in an error. Removing the source but keeping the dll made it all work fine. So far I haven't run into any bugs during test usage. :) I've also got other plugin dll's running in there and it's all going smoothly.

    Nicely done, will use and extend.

    Post edited by Firrerreo on
    My little chunk of the internet: http://artemic.com
Sign In or Register to comment.