PurgeandFire
zxcvmkgdfg
- Reaction score
- 509
GUI 101
Introduction:
"What will I learn?"
In this class, you will learn the basics and get an introduction to GUI triggering. I will post every Friday or Saturday, depending on how much time I have.
Lesson Plans:
Here are the lessons to be learned in class:
Introduction
- What is GUI
- How is GUI Useful
- How hard is GUI
Lesson 1: Lesson Date: April 27 or 28
- Triggers
- Conditions
- Actions
- Events
- Assignment
Lesson 2: Lesson Date: May 4 or 5
- Simple Text Display Trigger
- Variables
- Manipulating Variables
- Assignment
Lesson 3: Lesson Date: May 11 or 12
Code:
- Generals:
- Custom Scripts
- Setting Variables
- Integer Loops
- If/Then/Elses
Lesson 4: Lesson Date: May 18 or 19
- Presets
- Actions' Function Options
- Values
- Assignment
Lesson 5: Test Review Lesson Date: May 25 or 26
- Assignment (Test)
More to come soon...
Introduction:
GUI is an interface for JASS triggering. GUI stands for:
- [G]raphical
- ser
- nterface
GUI contains many triggers that help you make your game much more interesting and fun. GUI can help you do that and perform many things that you can't perform with just WE without triggers. Without triggers, many custom games would not exist and the melee games would be practically the only games to play! GUI is very simple and easy to understand, compared to JASS which is harder but proved to be more efficient. GUI is practically the first step in JASS, because most JASS tutorials require at least some knowledge of GUI. GUI is great for people new to the editor, so I will teach it so that everyone may learn.
Class Info:
The classes will have small lessons on each subject for the day, and you will be assigned homework after the lesson. The homework won't be too hard, I'll try to make it not too easy or hard, but average.
Posting Rules:
Please keep this thread empty of spam. Please do not post off-topic things, please keep it on-topic. You may make an off-topic remark or something like that, but please do not make it long so that it creates practically a sub-thread. Thank you!
Final Notes:
- Assignments aren't due, but it is good to turn them in...
- +rep to people who do well on their assignments
- If you need help, post here or wherever the lesson is.
- If you have any ideas/suggestions for lessons or general GUI 101, please post here or preferably PM me.
- I will only start this if at least 5 members sign up.
- You have until the next class, ( a week ), to complete the assignments.
- If you wish to be added, please post here, though you may PM me if you wish.
Members List:
- rodead
- hi_im_bob
- pheonixashes
- uareanoob
- thedude
- MapMaker
- MaaxeEvid
- Swish
- ~GaLs~
- denmax
- TheK1ll3r
- THE_X
- Lanboy
- trigger_newb
- Newbwc3
- Kota
- Norava
- Ghost32
- Enrutcon
- __________
- __________
- __________
- __________
- __________
Member Count: 18
[Note: As uareanoob said, this just makes it look organized, there is no limit to the members for this.]
Please join.
Thank you!
~Purgeandfire
Lesson 1:
Part I
Triggers:
Triggers are an area, that allows you to call multiple functions to configure your map. (M-W Definition: Something that acts like a mechanical trigger in initiating a process or reaction)
Triggers can allow multiple things in your game. If you have ever played a non-melee map, probably almost 90% or more of them are triggered. To create a trigger, you can do multiple actions to create it. There is a:
- Hotkey Way
- Icon-click Way
- Right Click the Category and click "New Trigger"
Before we do this, you must have the trigger editor open. To do this, you can either click the icon that looks like this: View attachment 8983, or click the hotkey (F4), or you can go to Module | Trigger Editor. Once you have that open, you can create a trigger.
Icon-Click Way:
You can click this icon to create a new trigger that is located in the upper trigger section toolbar that looks like this: View attachment 8984
Hotkey Way:
Have the trigger editor open and click "F4".
Right Click category and Click:
Or you can right click the category and click the "New Trigger" selection:
==--Example Picture:--==
View attachment 8985
After you've done that, you can name your trigger. Name it whatever you want, but make sure that it isn't the same as a current existing trigger you've made.
If you do that, it should display this in this order after you click it:
View attachment 8978
Part 2
View attachment 8980
Events determine whenever the trigger actually fires. Triggers do not run immediately after or when the game begins, unless you configure it to. There are a lot of events, so Blizzard put them into categories to help us out.
To create an event, you can simply click the event icon or press the hotkey (CTRL + E).
Then, choose your event and press "OK" so that it appears on your trigger.
View attachment 8979
Conditions are devices that allow you to have the game or an object or a player etc., meet certain requirements. Conditions, too, are organized in categories, though there are much more conditions than events. Conditions are categorized by what the requirement is. If you want to check if a unit is of the type "Footman" or any other unit type, you use go to "Unit-Type" comparisons. Boolean comparisons are much different than the other conditions. Boolean comparisons contain a lot of types of conditions, though they check if something is "True" or "False". This would be used to do something like this:
Code:
(Triggering Unit) is Dead Equal to True
This checks if the unit is dead. There are much more than just this, and they will extremely help in maps. Conditions can also be used in if/then/else functions, which I will talk about in another lesson.
To create a condition, click the icon (View attachment 8979) or you can just press the hotkey (CTRL + D).
View attachment 8981
Actions are certain functions that can be called. Actions are also organized in categories, and determine what the trigger will do. Actions are extremely essential to triggers, and they won't work without it unless your trigger does not need them, which I think is impossible, unless it is real weird or makes a unit do nothing or something like that.
Actions contain probably over 100 functions, which are all usable in your map. These contain many useful functions such as:
Code:
Unit - Explode <Unit>
To create actions, you can click the icon (View attachment 8981) in the toolbar above or click the hotkey (CTRL + R).
Browse through an select the one you like.
Assignment:
Difficulty - 0/10
Create a trigger named "Poo". Make the event "Unit - A unit Dies". Then create a condition that says "(Owner of (Triggering unit)) Equal to Player 1 (Red)". Then create an action that says "Unit - Create 1 Footman for Player 1 (Red) at (Center of (Playable map area)) facing Default building facing degrees".
Challenge:
If you want to challenge yourself and if you know this, fix the leak in the action by setting it to a variable and removing it.
Helpful Hints:
- Unit - A unit dies
Location : Events | Unit | Generic Unit Event
- (Owner of (Triggering unit)) Equal to Player 1 (Red)
Location : Conditions| Player Comparison
- "Unit - Create 1 Footman for Player 1 (Red) at (Center of (Playable map area)) facing Default building facing degrees"
Location : Actions | Unit | Create Units Facing Angle
Turning In Homework:
If you finish your really easy homework, you can post the trigger code here, or PM me, or even contact me through email:
[email protected]
I hope this helps!
Note To All:
I am still taking in students, so if you would like to join, you may post here.