Competition! Best GameSalad tips!
It's Humble Bundle time again, and I've been itching to play Day of the Tentacle Remastered for a while, so I just snapped the latest bundle up. There are several games in the bundle that I have no desire to play, though, so I thought I'd give them away on the forums for free!
To enter, write a comment with your best GameSalad tip. It can be a bit of logic you think is useful, or a way of better managing your workflow, or promoting your game - anything related to making games with GameSalad!
The three best responses will be chosen and given a key to one of the following games (entirely at my discretion - first place winner will get first pick etc.)
- Grim Fandango Remastered
- Worms Clan Wars
- Borderlands: The Pre-Sequel
- 80 Days
To be eligible to enter you must have a GameSalad account at least 1 week old (at time of posting). You do not require a subscription to enter. GameSalad is in no way associated with this giveaway.
This thread will be open for entries for 1 week, or until the thread drops off the front page, whichever comes sooner.
EDIT
Removed the Steam Code bit from the title since the contest is long over!
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
Comments
GSLearn.com | Templates | Free Demos | Udemy Course
Don't unlock actors in a scene unless you have a good reason for doing so. Unlocking an actor creates an "instance" that can have different rules (and even attribute values) than the original "prototype" actor. While sometimes useful, if unintentional this can make troubleshooting rules tricky because actors that appear the same can have unique rules.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Esc key works as the back button on android devices. So if you want to use the back button on android to pause your game .
when key esc is pressed
pause game
You can use the max function to compare many different numbers, not just 2 numbers like it shows by default. So not just max(x,y) but max(a,b,c,x,y,z). Same with the min function.
Very useful for many things, such as a aggro system for an RPG, comparing enemy distances, comparing high scores, or maybe a targeting system for an RPG, shooter, TD, etc.
Follow us: Twitter - Website
.
✮ FREE templates at GSinvention ✮
✮ Available for hire! support@gsinvention.com ✮
Tables.
My GameSalad Academy Courses! ◦ Check out my quality templates! ◦ Add me on Skype: braydon_sfx
Create an actor that is your master "controller" for each and every project you create. I call this actor RoundRules. My RoundRules actor is in charge of the "important" events in my game: saving and loading attributes, determining game over/level complete, resetting attributes and things like that. Localizing these events and behaviors can save you a lot of time later in development if you need to change something - Putting these "events" and behaviors in random actors can get extremely unorganized and can make you waste a lot of time looking for them, especially if you have a larger game with hundreds of actors.
My GameSalad Academy Courses! ◦ Check out my quality templates! ◦ Add me on Skype: braydon_sfx
Name every rule or group in your actor in relevance to its job so when making changes or bug fixing, you know what it does!
Already mentioned above but unlocking of actors in a scene unless needed is a massive no no as this always causes issues so if you do need to create an instance (an unlocked actor) then leave yourself a note stating why you unlocked it! For example to access scene layers or camera attributes. Always handy when tidying up.
Finally if you experience a freeze, check you are not referencing a table row or column equal to 0. This is normally caused by using an attribute to locate a certain row or column and having it set or reset to zero.
GAMESALAD DEV FOR HIRE! - www.gingagaming.com
I would add to this that you can vastly expand the flexibility and functionality of your actors through self.attributes
This way, you can have only one enemy actor, with all the necessary rules, with references to self.attributes as needed. You do NOT need to unlock an instance of an actor to change its self.attributes! So you can easily change the power, animation, etc. of each instance without breaking stuff by unlocking it. And you will only need to edit one master actor to update behaviours of the whole group!
Ask and ye shall receive. The forums are a great resource, ask clearly and you will receive an answer, even ones you dont like but you will get an answer.
With tables, make sure you add as many rows or columns as you will ever need. Especially important for saved level data. If not, you data will be rewritten when you make updated tables and you will lose your progress.
Sometimes I had many commands overlapping when I only wanted them to happen at certain times, so I added a game.Action attribute. Imagine making a slot machine...
For instance when game.Action = 1, then Spin button can be pressed. Once pressed, then set game.Action = 2.
If game.Action = 2, then wheels will spin and stop. Once all wheels stop, then game.Action = 3
If game.Action = 3, then check for win. If win then payout. If payout is complete, then game.Action = 1
Thats the basic idea... Before I had many True/False statements, but for me this is easier to see how things work in the order they're supposed to happen.
@Armelline Good idea
I need nothing for myself but instead I'll now pm you with gift links for "Her Story" and "80 Days", you are free to give them to whoever you want that contributes in this thread.
Often I made actors in a scene but I didn't want them visible so I changed them to alpha 0. But looking for them was difficult during edetting because they were well invisible. So now I leave the alpha to 1 but the first rule in them is alpha 0. So you can't see them during game play but during editing they show up...........
Make sure you create your tags before adding the actors to the game. If you don't do it the engine won't detect the tags and you will have to delete EVERTHING and make it again.
Thanks @JSproject! That makes for five prizes to be given away!
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
Super nice idea @Armelline
When you spawn actors and need to pass a value to them, use the Rotate, X or Y attributes to send a value.
e.g. to set the type of enemy spawned
In the Spawner Actor
In the Enemy Actor
Now you can have rules in your enemy setting its image, health, speed, etc. depending on its type.
This saves you from creating multiple actors for each enemy type.
Not my idea, but learnt in this excellent forum.
MESSAGING, X-PLATFORM LEADERBOARDS, OFFLINE-TIMER, ANALYTICS and BACK-END CONTROL for your GameSalad projects
www.APPFORMATIVE.com
Great idea @Armelline ! . . . . not only is it a nice idea for a competition, but you also create a thread full of really useful tips ! (Why on earth are GameSalad not engaged like this ?)
One of my favourite pieces of logic is . . .
1-X
Where X is an attribute and starts out as 0 or 1, repeatedly changing X to 1-X toggles X between 1 and 0, which is really useful for things like flashing lights . . .
Every 1 second
Change Alpha to 1-Alpha
. . or for things like sound/mute buttons . . .
When pressed
Change Sound volume to 1-Sound volume
. . and so on.
@Armelline very useful idea!
When spawning to many instances of one object and you need "identify" each instance:
Create a global variable "counter" as integer, to number and counting these instances and in object a local variable "whoiam" as Id for this instance.
Then at the beginning of rules of this object:
counter= counter +1
whoiam = counter
You can use "whoiam" has Id for this instance, to index parameters in table, etc
Here is a general tip (more like a mistake i used to make alot).Putting a rule inside a rule can save you alot of time. I used to complicate things when i started gamesalad. For example , If I wanted to do something like this
I would create 4 different rules
Then few months later i realised i can just put a rule inside a rule , this made alot of things much easier and allowed me to use "or" & "and" together in a rule.
2 different ways to do the same thing, but you will have less code to handle and it will be easier to change and organise.
My favorite way of picking a random left/right movement
Direction = random(0,1)*2-1
Movement = SomeSpeed * Direction
MESSAGING, X-PLATFORM LEADERBOARDS, OFFLINE-TIMER, ANALYTICS and BACK-END CONTROL for your GameSalad projects
www.APPFORMATIVE.com
Yeah, I often use that one too !
It's also useful for selecting a random number from a range that spans negative and positive numbers . . . without getting a zero.
So something like . . . . (random(0,1)
*
2-1)*
random(1,100) . . . will give you a random value between -100 and 100 except for zero.Every 5 minutes click that save button or after being successful with a difficult logic. Also duplicating your gamesalad file before opening a just updated gamesalad software is a great idea.
You can use your own sql server to send and receive anything you can think of:
Sending and Receiving data using your own SQL Server
You can also generate your own Unique Identifier for your game to track how often people play, how far they get, etc... It does reset if they delete and re download the game however. http://forums.gamesalad.com/discussion/66786/generating-a-unique-id-for-asyc-metrics-whatever#latest
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
One day left for submissions!
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
Use inline LUA functions to perform string operations in the expression editor:
e.g.
Convert a string to Uppercase
Convert a string to Lowercase
Reverse a string
Here is just one example of how to use it, although it works anywhere where you use the expression editor - like in a Change Attribute behavior.
MESSAGING, X-PLATFORM LEADERBOARDS, OFFLINE-TIMER, ANALYTICS and BACK-END CONTROL for your GameSalad projects
www.APPFORMATIVE.com
An example, struggling to implement this.
@fmakawa I updated my post with an example.
MESSAGING, X-PLATFORM LEADERBOARDS, OFFLINE-TIMER, ANALYTICS and BACK-END CONTROL for your GameSalad projects
www.APPFORMATIVE.com
You can open 2 projects in 2 instances of GS and copy rules from one actor from project 1 and paste in other actor of project 2