Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Save/Import/Export characters #6

Open
sander1095 opened this issue Dec 29, 2016 · 2 comments
Open

Save/Import/Export characters #6

sander1095 opened this issue Dec 29, 2016 · 2 comments

Comments

@sander1095
Copy link
Owner

sander1095 commented Dec 29, 2016

Allow the user to save/import/export certain characters in a certain file format (JSON?) or SQLite database (with Entity Framework?) so it can be loaded after closing and opening the program again, or when loading it onto a different computer. You could maybe carry a USB Stick with the file on it, or save it somewhere in the cloud and then download it and import the characters.

@sander1095
Copy link
Owner Author

sander1095 commented Mar 28, 2017

The way it is probably gonna happen:

  • Save a .json file to the Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData folder. (Create a folder in there called D&D Combat Tracker. The file will be called Characters.json
  • The file will contain a list of categories. A category is a name (of the category) and a list of characters. (This is handy because users will be able to create different categories for different campaigns or something)
  • Allow the user to access this file by implementing Add a "Main Menu" bar. #16 . By clicking on a certain option he can open a GUI and add/edit/delete/add categories/characters to current list/import*/export* categories and characters. He should be able to add (items from) multiple (and different) categories to the current list at the same time.

*Not planned for the first version:

  • Allow the user to import a character from a different location (USB drive or something). It will overwrite OR let the user choose what file to use.
  • Exception handling (what if the software can't write to the disk, what if the file is deleted while doing things)

sander1095 pushed a commit that referenced this issue Mar 28, 2017
sander1095 pushed a commit that referenced this issue Mar 28, 2017
… I try to start the application. Whoops.
sander1095 pushed a commit that referenced this issue Apr 4, 2017
…ed working on save/import/export characters

Increased version to 2.1.7.0 in About pop-up and Assembly file so I don't forget to do that the next time I publish something.
sander1095 added a commit that referenced this issue Oct 6, 2019
The code has been pushed to "6-save-import-characters"
@herrozerro
Copy link

I'd like to take a stab at this.

I am thinking about a PartyManagerService and a Party class.

public class Party { public Guid partyId { get; set; } public string Name { get; set; } public List<Character> Characters { get; set; } public string Notes { get; set; } }

the manager service will expose the following:

  • GetParties: returns a list of all currently saved parties
  • SaveParty: looks up to see if a party currently exists. If so, updates the party, otherwise saves a new party
  • SaveParties: (might be private) saves all parties to file.

herrozerro added a commit to herrozerro/DnDCombatTracker that referenced this issue Oct 11, 2019
…h are lists of characters, Added newtonsoft to forms to it works. sander1095#6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants