• 0

    posted a message on Larva spawning

    @jcraigk: Go

    Was this on a placed Hatchery or on one that was spawned via a trigger? I'm either not duplicating your method well enough or this method won't work for a Hatchery spawned via a trigger. T_T

    Posted in: Triggers
  • 0

    posted a message on Newb, in need of guidance

    @Frethen: Go

    One more piece that I've been working on tonight, even, is creating a good test environment.

    Right now it's temporary (I haven't even started researching how the Battle.net Lobby will interface with my map, so it's kind of jury rigged at the moment) but when the player selects their race from a dialog at the start of the game, I added a few triggers to give each race like 9000 minerals/gas so you're never stuck waiting for resources to begin testing a specific case scenario.

    I've also begun filling out a Debug folder full of other useful triggers to help expedite testing such as one that whenever a unit begins construction, set the construction progress to 100% so buildings finish instantly. Also when a unit takes damage to kill it since you always start with a worker.

    If I want to test my systems against different scenarios, having the money right off the bat and the ability to build and kill things instantly saves loads of time. Getting these debug triggers up and running is really helping my testing out a ton. Though technically my debug tools aren't complete yet... now I'm stuck trying to figure out how to handle the snowflake Zerg... I've spent hours searching and I can't find an elegant way to make the starting Hatchery spawn with full creep spread out or 3 larva. (Or just have all creep "build" instantaneously) There's actually a thread on the front page right now addressing the 3 larva spawn issue, but trying his method, I haven't been able to get it to work. >_<

    So the ultimate purpose of this map is to be a blank canvas, so to speak; when I begin constructing a new system, I can do so in this fresh, modularized test bed and save the map as a different name to store just my work pertaining to the specific system I'm building. When I've finished construction of it and it's ready to go, I can just collapse a folder and copy/paste it into my main map. From there it's just making sure I hook up all the systems to be able to communicate with one another and it saves me a lot of headache by being able to get each component up and running on its own before adding it to the machine.

    Honestly I've restarted this project from scratch like 6 times now because I keep learning more about the editor and finding more efficient ways of handling my systems. I think this modular template system is going to save me a lot of time, headache and confusion in the long run, so it may be something worth considering. :)

    And one last thing - I found that creating a diagram has helped me plan out my systems immensely. I currently am using my closet doors (ceiling high mirrors) like whiteboards to brainstorm on, then I picked up a little freeware program called Diagram Designer off of Tucows and I begin "sketching" out the system there. Sculpting out a model of the intended system design has helped me a lot when it's time to get into the thick of things, especially when you take a break and do something called "sleeping" that interrupts your thought process for several hours on end. Having a diagram of what to do makes it much easier to get back into the groove.

    Posted in: Triggers
  • 0

    posted a message on Newb, in need of guidance

    @Frethen: Go

    All seems fairly "easy". http://wiki.sc2mapster.com/galaxy/tutorials/ would probably be where you'd want to start looking at tutorials.

    I learned this the hard way (holy crap that was a frustrating week), but when you create a new Variable (and you're going to create lots of them), don't forget to set what type of Variable it is. Just to the left of the Initial Value field is a drag down menu of different Types to set the variable to. This is how you make your variables visible when you're trying to hook things up; doing functions with Units require Unit Variables like doing functions with Unit Types require Unit Type Variables like doing functions with Integers require Integer Variables, and so on.

    As far as what to really investigate, it seems like the most complicated part of your system is going to be the Dialog work; just going to be lots of computing the "rolled" integers, setting the acceptable stat thresholds to make your Heros visible and actually hooking it all up via Dialog Items. You're probably going to create 1 or 2 Dialogs and then constantly switch out the Dialog Items within it.

    Beyond that I'd recommend researching Arrays, because learning what an Array is and how to utilize it will save you a lot of time and effort and create cleaner code. For example, if you're planning on a party of 4 players, you would have a Player_Stat Array that is 2 dimensions deep - [4][3]. Then you can use those indexes in the Array to store the randomly generated integers and every time a player clicks Reroll, run the random integer Trigger again and continually rewrite over the applicable player's array indexes. (Indexes are basically coordinates in an Array, and I visualize an Array in my head like tournament brackets. Not everyone does, so your mileage may vary)

    Also another thing that will be of super, great, ultra, mega, hyper, giga importance to getting started and making tangible progress early on is learning how to debug your work. You could spend hours implementing something, thinking it's going to work because it appears logically sound in your mind and then when you go to test it - it doesn't work and you have no idea why. First thing you want to do is get familiar with how your system is actually working, so whenever you are performing Actions through your Triggers, make one more Action at the very end that is simply Action - Text Message. Print out a helpful message to the chat that lets you know during testing when something just happened. If you're expecting a message to fire and it doesn't, you at least know the last message (Trigger) that fired properly. This will save you lots of time in hunting down the cause of the bug.

    If you're looking at, say, knowing what value something is, you can create a Text Message, then do a function called Combine Text and then put your first Text as "Number of Apples: " then make the second piece of text a Convert Integer to Text and plug in your AppleCount variable into it. There is a debugger tool that comes with the editor itself (that you'll hear about when you watch Beider's Trigger Debugging video) that will let you see the values of variables in real time, but know that the debugger is going to make your game slower andl once you really start getting something complex going, it can run at less than 1fps and take forever for some things to test. If you just need to do quick tests, and the game runs that slow, you can use Combine Text's on a Periodic Timer Event to constantly output a variable's count without slowing the game down through the debugger and wasting time.

    Take it very slow and methodical; try to accomplish a little, then test it to make sure it's working as intended, then go back to the trigger editor and iterate a little more from there, fire up the map to test it, rinse, lather, repeat.

    Also if you make SC2 open in a window and just leave that window open in the background, you'll save a lot of time when you're compiling your map to test it.

    I'm still pretty green myself, but this is how I make progress. Beyond that, it's an ocean of knowledge trying to learn exactly how to make what you want to have happen with the editor, but most of that comes through just learning and knowing your way around the editor itself.

    (Jesus, I'm sorry this all ended up so long winded...)

    Posted in: Triggers
  • 0

    posted a message on Larva spawning

    @jcraigk: Go

    Was this on a static Hatchery you placed on the map manually or one that is created if the user selects Zerg?

    Posted in: Triggers
  • 0

    posted a message on Can Functions Output to Other Functions?

    @FuzzYD: Go

    Honestly I don't even know what a data table is, aside from one exists, you can't make more and you just put information there.

    It never really sprung out at me as a solution to investigate because the properties of the units I'm going to be tracking are going to be queried and calculations done on those queries about once a second and the information needs to be created and erased as units are born and die.

    Would a data table be an ideal solution for something like that, complications be damned?

    Posted in: Triggers
  • 0

    posted a message on Can Functions Output to Other Functions?
    Quote from Obatztrara: Go

    You can not return or pass over arrays.

    I like the idea on the global variables, that's good. I could then make a trigger with no events that writes those variables into the array, but is manually ran at the end of the function's actions, yeah?

    Posted in: Triggers
  • 0

    posted a message on Can Functions Output to Other Functions?

    Can I make a Function that will calculate all that I need it to, then as a side process, output the information to another Function to do additional actions? The reason is I need to have 2 different kinds of outputs, one being Integers and the other being Reals and the second function is completely dependent upon the output of the first function.

    So what I'm trying to accomplish is 1) dynamically entering information into an array for a new unit that meets proper conditions and 2) taking the integers that go into the array and making a unique identifying ID which then is set to a triggering unit's Custom Value (because I'm trying to track properties of that unit).

    Here is a quick diagram I drew up to try and demonstrate what I'm trying to accomplish.

    http://i.imgur.com/eII1N.png

    I haven't made a map or mod before, so I'm still trying to learn as I go... but is this even possible? Or is there a better way of handling this?

    Posted in: Triggers
  • 0

    posted a message on Seeking a gentry to look over some triggers

    Welp, nevermind.

    Posted in: Triggers
  • 0

    posted a message on Seeking a gentry to look over some triggers

    Greetings gentlemen and gentlewomen, I'm currently looking for someone very experienced with triggers to look over a map I'm creating. When I started, I knew only a bit about the Data and Terrain sides of the editor, and now I'm nearing completion of my first actual scripted "milestone". There are still a few kinks to work out and a list item to create, but I'm at the point where I'm concerned about the efficiency of how I'm handling the triggers.

    Is there anyone who might be able to spare some time to review my triggers and, ideally, communicate over an IM? (I may have taken 5 days off of work to crank on this project, so rapid communication is preferred. ^_^) If you're interested, we can swap info through PMs. Thanks!

    Posted in: Triggers
  • 0

    posted a message on Need something created for you?

    @deathtorn: Go

    Thanks man! Though I'm having some trouble figuring out how to set the custom variable to "Nexus" specifically so I can use this custom variable in triggers to determine if it ever goes idle or has too much Energy according to a value I set. All I get are "No Unit", "Any Unit" and "Any Item", none of which let me actually set the Nexus unit specifically.

    And speaking of which, I've tried to create triggers that monitor the Energy of a Nexus and for the life of me, I'm struggling to find it. And I can't figure out how to relay text messages specifically to Observers in the map, not the actual players. -_-

    It's been a frustrating, no-progress kind of past couple days. I hate to continue to pry information out of you, because it feels like cheating to my learning the tools, but apparently I just am not getting it. If I knew the language syntax and all the back end functions and values, I could probably just write the goddamn script without using this lego-block style script assembly. I just don't get why I'm struggling so much to pick up on such a robust tool set. It seems like it would be easier than anything else I've worked with. -_-;

    Posted in: Triggers
  • 0

    posted a message on Need something created for you?

    Hey deathtorn, just wanted to say I think it's pretty awesome you're stepping up to help out so many random people. :)

    Also wanted to ask a question for you... so long story short, I'm trying to add triggers into a map that will give real-time feedback to the user. When their macro slips, they receive a notification. The goal is to have one for workers not building and Energy stockpiling... but here's what has me stumped - I think I've figured out the triggers to make this happen, but I can't set the buildings as Values because there are none on the map. (Start Locations not actually providing the buildings to hook up as Values, since Start Locations are technically Points)

    Any ideas?

    Posted in: Triggers
  • 0

    posted a message on Buildings do not idle?

    @HellsAn631: Go

    I was curious if you have by chance figured out a better solution since. This is highly relevant to my interests and will soon be a problem I need to solve this week. ;)

    Posted in: Triggers
  • To post a comment, please or register a new account.