Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by diddykonga · Jul 02, 2012 at 11:07 PM · savefilecombo

Saving script variations

Im working on a brawler game with different combo and fighting style, and i need a way of saving different variations of my ComboType script.

Does anyone have an idea how i can save a script with it being modified with information filled in it?

(Not looking to use XML serialization, because Unity doesnt export the .Dll with the build)

Comment
Add comment · Show 3
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image syclamoth · Jul 03, 2012 at 12:10 AM 0
Share

This is what we have fields for public values in the inspector for. Why can't you just use those? They serialise automatically, without need for any external libraries, and are the most straightforward way of storing any configuration data you may need.

avatar image diddykonga · Jul 03, 2012 at 05:29 AM 0
Share

The reason why is because i need to be able to save multiple varaitions and be able to load multiple of them in at load time, and from my knowledge you cant make a prefab out of just a script?

avatar image diddykonga · Jul 03, 2012 at 08:18 AM 0
Share

What?? 0-o

1 Reply

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by flamy · Jul 03, 2012 at 05:49 AM

what does dll not supported means. Why do you need dll when System.XML classes work on all platforms, (though some won't in android) but it is good enough in your case, because you are just gonna read from the xml file not write it back (I'm saying this because i never tried writing in the device. writing may also work)

I was able to use all functions of XMLDocument class in device. Also XMLNodeList, XMLElement, XMLAttribute classes.

With my little knowledge, i can say that reading from xml seems to be the best in this case.

Comment
Add comment · Show 8 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image diddykonga · Jul 03, 2012 at 05:53 AM 0
Share

I tried using Xml serialization, but i had to find and include a .dll when i make my build, because Unity strips that funcionality when it exports a build. I suppose if theres no other way around it, i just really dont want have to include extra .dll's

avatar image flamy · Jul 03, 2012 at 06:06 AM 0
Share

hmm i didn't suggest you to use X$$anonymous$$LSerializer, which is stream based.. what i suggested is to use X$$anonymous$$LDocument, which is text based. ofc X$$anonymous$$LSerializer needs the dll to be added. Is there any special reason why you want to serialize your xml??

avatar image diddykonga · Jul 03, 2012 at 06:21 AM 0
Share

Oh ok nvm i see, is X$$anonymous$$LDocument supported without having to include any extra .dll's? and do you know of any easy way of ecrypting Xml files? Thanks :)

avatar image flamy · Jul 03, 2012 at 07:20 AM 0
Share

do you want to encrypt it while in editor and decrypt back and use xmlDocument something like this!??!

im not getting you

avatar image diddykonga · Jul 03, 2012 at 07:25 AM 0
Share

Sorry should probably explain more, im making a brawler game, so i make the combos in the editor filled with information, so that during the game the characters can load them in and use them.

So i need to be able to save them, and be able to load them in during runtime, but if i could find a way to encrypt them when i save them, that would keep them from being changed by the user

Hope that explained things better :)

Show more comments

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

7 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Change location of binary file created when saving 1 Answer

Create Transform from prefab file in a project 4 Answers

Saving and loading scene specific data - (safe for scene renaming) 1 Answer

Sending Variable to Highscore Server results in 0. 0 Answers

how i can save big text files in web player? 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges