I have development experience and have some map ideas I want to try out in the editor. However, I only want to even attempt these ideas if the map editor can support them. I'm not looking for any help at specifically writing functions at this time. Just a simple "yes" or "no" will work. Also, I've gone through a few tutorials and have a general understanding of how to setup basic triggers, actors, etc.
1) Does the editor/map still crash if you have "too many" doodads? It seems this was a problem during/after beta. If Yes, what is the general limit?
2) Is it possible to systematically create and destroy doodads while a game is in play?
3) Is it possible to write functions with multiple conditions? For example:
While (val > x) {
If statement
Switch
endif
Assign updated values
}
4) Is there an RNG function I can use?
I’ve done some very light searching on these items so if I missed a thread don’t hesitate to direct me to it.
Maybe. There is not precise data available on a doodad limit. All pre-placed objects in a map are defined in the xml files in the map mpq, so if there is a hard-coded limit, it should be trivial to determine. "Fuzzy" limits may exist with regards to how much memory the editor can allocate to them or how much your computer can handle rendering.
Yes-ish. Doodads are not an object type well-handled by the current API, but actors and units are, both of which can be created at run-time and are supported by a robust (if not exactly complete) API. If you don't need footprints for your dynamically generated pseudo-doodads, you can use actors; if you need footprints / collision, use units.
Yes. while, do while, for, and if else flow controls are supported natively in galaxy, and GUI offers additional flow control constructs like Switch on top of these.
Yes-ish. The engine's RNG can be used and manipulated, offering the user options to set and lock seed, which is desirable if you want to use the engine RNG for repeatable, procedurally-generated content. Additionally, I can provide a pretty robust RNG script if you want to take a look.
For the doodad question, I want to focus on the create/destroy piece real quick in the following scenario:
Step 1) Map loads (i understand terrain loads only one time...i think)
Step 2) Doodad is placed at position X,Y
Step 3) Objective is complete
Step 4) Doodad is removed from X,Y and placed at A,B
As for your RNG script, I would love to see what you got.
I would use units for elements that are not entirely decorative, which is to say if they act on or are acted upon by other world elements.
Here's the RNG I used for procedural generation in a super-map proof of concept about a year ago.
// Pseudo-random generator based on George Marsaglia's// Multiply-with-carry method.// NOTE: Seeds must be non-zero.intPRNG_SEED_X=1;intPRNG_SEED_Y=1;intPRNG(){PRNG_SEED_X=36969*(PRNG_SEED_X&65535)+(PRNG_SEED_X>>16);PRNG_SEED_Y=18000*(PRNG_SEED_Y&65535)+(PRNG_SEED_Y>>16);return(PRNG_SEED_X<<16)+(PRNG_SEED_Y&65535);}
In a major patch or two, I expect (hope) we'll see some additions to the language that makes implementing more complex and secure RNGs practical; porting a Mersenne Twister to a procedural language without native pointers or references is a pain.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hello,
I have development experience and have some map ideas I want to try out in the editor. However, I only want to even attempt these ideas if the map editor can support them. I'm not looking for any help at specifically writing functions at this time. Just a simple "yes" or "no" will work. Also, I've gone through a few tutorials and have a general understanding of how to setup basic triggers, actors, etc.
1) Does the editor/map still crash if you have "too many" doodads? It seems this was a problem during/after beta. If Yes, what is the general limit?
2) Is it possible to systematically create and destroy doodads while a game is in play?
3) Is it possible to write functions with multiple conditions? For example:
While (val > x) {
If statement
Switch
endif
Assign updated values
}
4) Is there an RNG function I can use?
I’ve done some very light searching on these items so if I missed a thread don’t hesitate to direct me to it.
Thanks!
Thanks for the quick reply Jade,
For the doodad question, I want to focus on the create/destroy piece real quick in the following scenario:
Step 1) Map loads (i understand terrain loads only one time...i think)
Step 2) Doodad is placed at position X,Y
Step 3) Objective is complete
Step 4) Doodad is removed from X,Y and placed at A,B
As for your RNG script, I would love to see what you got.
I would use units for elements that are not entirely decorative, which is to say if they act on or are acted upon by other world elements.
Here's the RNG I used for procedural generation in a super-map proof of concept about a year ago.
In a major patch or two, I expect (hope) we'll see some additions to the language that makes implementing more complex and secure RNGs practical; porting a Mersenne Twister to a procedural language without native pointers or references is a pain.