I’m building a car racing game, and I want to record the path where my car drives by, and then apply it to other car.
A bit like JCarRecording, when it instanciates a ghost car on second lap.
The diference is that I want to record the values, stop game and keep a record of all the changes during the game, so I can apply them to another car.
I’ve build an array that keeps position, rotation, velocity, accelaration, steering and gear of the car in each frame. But when I stop the game, I loose all of this information, as normal!
What I’m asking is that if there’s any way to write a file with the values changes, or keep it in some kind of memory, so I can re-use this information after stoping the game.
You would use WWWForm to upload the data to a web server. The class has a method called AddBinaryData that you can use to send your recorded path data along with the form. You would also need something on the web server to respond to the incoming data. This would probably be a simple script that stores the data in a database. To retrieve the data, you would need another script on the server that responds to the request - you would pull the data into Unity using the WWW class.
Sobral did you ever get this working? I have working code to store and retrieve physics and transform information persistently in playerprefs, guessing it’s of little use to you now but let me know if you want it.
I can’t get wwwform to store on files on my server though, did you ever get that working?