• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[JASS] Game Cache

Status
Not open for further replies.
Level 8
Joined
Jul 28, 2008
Messages
211
Hi!

I want to know how can i get a stored unit with jass.

I tried reading a few tutorials but all i saw was :

Now, storing and getting units is a pain in the ass, and everything else than boolean, string, integer and real is nearly impossible, or very annoying to do all the time, to do without a system.

I've heard about local handle vars and structs, but I want to know how to do it without any of those.

Thx!
 
Level 16
Joined
Mar 3, 2006
Messages
1,564
JASS:
native InitGameCache takes string campaignFile returns gamecache
this is similar to
  • Game Cache - Create a game cache from MapName.w3v
but not the same as the JASS one is native and the trigger one is BJ, which calls the native one.
---
native StoreBoolean takes gamecache cache, string missionKey, string key, boolean value returns nothing Stores Boolean
native RestoreUnit takes gamecache cache, string missionKey, string key, player forWhichPlayer, real x, real y, real facing returns unit Restors unit from a cache.
native ReloadGameCachesFromDisk takes nothing returns boolean in triggers
  • Game Cache - Reload all game cache data from disk
<< ADDED >>
JASS:
native FlushGameCache takes gamecache cache returns nothing
similar to
  • Game Cache - Clear (Last created game cache)
 
Status
Not open for further replies.
Top