Saving Problem

lummerlars

Member
Reaction score
2
Hi everyone. Im doing a Map with my friend. It's my job to make the Save/load System. I have made the Hero, level, gold and lumber save. But now i got a problem. I cant save my items. My question for you is:
How do i save my items. I realy appreciate if you can help me.

I give 1 rep. to the one who can help me.
 

jomik

New Member
Reaction score
17
Just get the ID of the item, and save it in a code? - encrypt it in some way ? :D

EDIT: Ohh, it's you dudes whos making the ORPG? :D doing it in JASS or GUI?
 

Weirdoze

New Member
Reaction score
6
Just get the ID of the item, and save it in a code? - encrypt it in some way ?

Sorry to say this, but that comment did not help very much. You just presented 2 more questions.
 

lummerlars

Member
Reaction score
2
Set TempItem = (Number of items carried by (Picked unit))
For each (Integer A) from 1 to 12, do (Actions)
Loop - Actions
If ((Item carried by PickedHero in slot (Integer A)) Equal to (Item carried by PickedHero of type ItemType[1])) then do (Set Code = (Code + ItemString[1])) else do (Do nothing)
If ((Item carried by PickedHero in slot (Integer A)) Equal to (Item carried by PickedHero of type ItemType[2])) then do (Set Code = (Code + ItemString[2])) else do (Do nothing)

I know that the ending Action is = Do nothing. That not the action it should be. But im totaly lost.
 

jomik

New Member
Reaction score
17
Sorry, I'll give ya a code that might work :D
Ahh, fucked, this'll be easier if you use JASS lol :p Otherwise you'll have to do as lummerlars said, even though you could give each item a custom value, and save that in the save code, then when they load, check for custom values.
 

lummerlars

Member
Reaction score
2
We're actually makeing a map. We are not Scripting :D.
We're trying to make this work, without useing jass.
But the problem with GUI is: that it's hard to do alot of thing on the same time, with the right effect..
 

Weirdoze

New Member
Reaction score
6
Hmm, and exatcly what for?
Let's say that it would take a month to learn JASS basics
then few months more to learn more advanced things like saving codes
and then i make epic-super-uber-cool-badass-JASSmaps for a year or two
and some day i wake up in the reality :O
There are actually no one who plays wc3 anymore
Damn I just wasted nearly 6 months of my life and I know JASS
What does it help in later life?
 

millz-

New Member
Reaction score
25
I would say there is 2 main ways of saving items. The first way is to save the item type id of an item. Another way is to store all items you have in your map to an array, then check the item carried by the hero is which item in that array, when you found the right item, save the index (which is also something like saving the custom value).

Of course there should be other ways but could be complicated, or maybe not, I don't know. Also, saving item type id will usually return a very long code if the hero has 6 items, so saving the "index" or "custom value" of an item would be more feasible.

Edit:
@Karri
Do you believe I started mapping only about 20 days ago? I admit I have learnt some sort of programming before, like Java and C++ so it's quite easy for me to catch up with JASS. :p
 

lummerlars

Member
Reaction score
2
I would say there is 2 main ways of saving items. The first way is to save the item type id of an item. Another way is to store all items you have in your map to an array, then check the item carried by the hero is which item in that array, when you found the right item, save the index (which is also something like saving the custom value).

Of course there should be other ways but could be complicated, or maybe not, I don't know. Also, saving item type id will usually return a very long code if the hero has 6 items, so saving the "index" or "custom value" of an item would be more feasible.

First of all. Im trying to make the second one: Saving all items to an array. And it worked nice. But the problem is when i have to save them, it's doing a separated save code.
1
1e
1ew
1ewD
1ewDT
1ewDTk Like that
Else it's not doing what i want it to do. Like doing only one of the Item codes.
So i dont know what to do, with it.
 

UndeadDragon

Super Moderator
Reaction score
447
ehh.. but as I understood Visual Basics is easier to learn, and it helps learn other programming languages 100 times better :D

Visual basic syntax is horrible compared to most languages.
 

Azlier

Old World Ghost
Reaction score
461
I took 3 days to learn Jass, 4 more to learn the vJass stuff like structs.

No previous programming experience. Saying it takes 6 months is pure exaggeration.
 

lummerlars

Member
Reaction score
2
This Thread was about a save/load system.
You aren't getting any rep+ just becouse your telling about jass:)
Please i need help.
 

Weirdoze

New Member
Reaction score
6
I took 3 days to learn Jass, 4 more to learn the vJass stuff like structs.

No previous programming experience. Saying it takes 6 months is pure exaggeration.

PLEASE, don't make me repeat myself, I said that I was wrong :S!
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top