The Daily Click ::. Forums ::. Team Projects ::. How to save score on harddisk? (CnC or MMF1.0)
 

Post Reply  Post Oekaki 
 

Posted By Message

Patrick Schmitt



Registered
  20/03/2006
Points
  4
20th March, 2006 at 08:21:54 -

I want to create a game with several rooms where you can collect items. How can I save room-number and the items the player has on hard disk, how to load them...?

Can you give me an example with 2or3 rooms and 2or3 items that I can use and expand...

I use "Click&Create" or "MultimediaFusion V1.0"

Thank you very much
Patrick



patrick@schmitt-dahlen.de

 
n/a

Deleted User
20th March, 2006 at 12:18:02 -

the simplest way is the INI object, see it's examples (should be on MMF1.0 CD i think)

 

Radix

hot for teacher

Registered
  01/10/2003
Points
  3139

Has Donated, Thank You!VIP MemberGOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!
20th March, 2006 at 14:20:01 -

You'd be better off with an array for more complex games. Otherwise you have to define the groups/item names to save to the ini for each value.

 
n/a

Arneckian



Registered
  17/01/2005
Points
  984
21st March, 2006 at 08:17:19 -

Why are you using MMF 1.0 and CnC???

 
Phizzy is God. Mod him.

Patrick Schmitt



Registered
  20/03/2006
Points
  4
21st March, 2006 at 09:05:43 -

Im using CnC or MMF1.0
Is it better to use a highter Version of MMF to solve my problem?

 
n/a

DaVince

This fool just HAD to have a custom rating

Registered
  04/09/2004
Points
  7998

Game of the Week WinnerClickzine StaffHas Donated, Thank You!Cardboard BoxDos Rules!
21st March, 2006 at 15:33:00 -

No, but MMF 1.5 is MUCH better than 1.0, and you have access to more extensions.

Anyway, for simple file save things, just use the INI object.
* At the start of the frame:
- Set ini file to Appdrive$+Appdir$+"filename.ini" (or another fitting filename).
- Set group to "game" (or another fitting group name).

* When entering a room (save):
- Set value of item "Current room" (or another fitting name) to value of <roomnumber>.

* When picking up an item:
- Set value of item "Item Shovel" (or another fitting name) to value 1.

* When entering a room (load):
+ Compare 2 general values: Value of [Get ini item "Item Shovel"] is equal to [1]:
- Destroy the item in the room, as the player already has it.


I'm sure you can figure out more yourself, just practice using the INI object a bit.

 
Old member (~2004-2007).

Patrick Schmitt



Registered
  20/03/2006
Points
  4
22nd March, 2006 at 15:10:50 -

Thanks... I'll try it...

 
n/a

Patrick Schmitt



Registered
  20/03/2006
Points
  4
24th March, 2006 at 08:29:12 -

Wow! It works! I'm happy

 
n/a
   

Post Reply



 



Advertisement

Worth A Click