Hi, why don't we try listing down easily misunderstood concepts in the SC2 editor?
Player Groups:
If you set Player Group Variable A = Player Group Variable B
then if you remove all players from Player Group Variable A, you remove all the players from Player Group Variable B.
In other words, setting a player group variable to another player group variable is just creating a reference of that other player group rather than copying the players of that other player group.
Pretty cool revelation for me.
Rollback Post to RevisionRollBack
Member since 2010. Made the -The Thing- [Revival] game. Nostalgic of the WC3 days.
Is there any list where I can see which object type is a reference?
Good question, I dont know to be honest. Havent seen any yet. :(
As a very simple rule I would probably say that all primitive types arent references while all "ingame" objects, such as regions or units are referrences. Actually, nearly all types are most likely references or "fake" gui types, including actors, banks, triggers, timers, objectives, text tags ...
Then, there are also some exceptions which could be referrences but are immutable, strings for example. Then there are even other types which are just "fake" types in gui and just represent ids in galaxy, for example dialogs and dialog items which are just ints in galaxy and therefore technically are no referrences, but then again they are indirectly because they just represent an id for an object managed by the game engine. So even though you are technically passing a copy to another function you can still modify the passed dialog or dialog item within it.
Might be useful to compile a list, but that would definatly require some effort and time.
That chart can serve as a listing of every type supported by the game and its characteristics. But it doesn't identify this kind of types that have 'reference' semantics, f.e. trigger is 'reference' based, but it doesnt extends handle, as do the most of the handle types that surely are 'reference' types. I think we can name those types as 'complex types'. And as already noted, integers can also be complex types when they refer to dialogs, for example.
Haha, sure, if you believe that the fundamental value types and operators that significant portions of the galaxy API depend upon would be changed ever, then I can see why you'd err in thinking Deaod's work could be outdated. Better still, by your own admission you assume the operator precedence table which you copied from your reference material on C, rather than actually test it, is more accurate than the table composed by the person who actually tested it.
This appears to be a case of rapidly-progressing acute NIH Syndrome.
I made those some time ago, and discussed many of my assumptions with Deaod himself, he told that he hasn't made many tests, and my chart would be more complete, I probably tested it more than he. So plz shut up.
Anyway, I didnt made it as the ultimate reference for Galaxy, It just some notes of what I need to know for making sure my parser is correct
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hi, why don't we try listing down easily misunderstood concepts in the SC2 editor?
Player Groups: If you set Player Group Variable A = Player Group Variable B then if you remove all players from Player Group Variable A, you remove all the players from Player Group Variable B.
In other words, setting a player group variable to another player group variable is just creating a reference of that other player group rather than copying the players of that other player group.
Pretty cool revelation for me.
Member since 2010. Made the -The Thing- [Revival] game. Nostalgic of the WC3 days.
Whats so surprising about that? Same happens for lets say, units or dialog items.
Many objects are just references.
@Mille25: Go
Yes, and many people don't know this, it took me a while to figure this out, thats why it could be misunderstood by people.
@Mille25: Go
Is there any list where I can see which object type is a reference?
Good question, I dont know to be honest. Havent seen any yet. :(
As a very simple rule I would probably say that all primitive types arent references while all "ingame" objects, such as regions or units are referrences. Actually, nearly all types are most likely references or "fake" gui types, including actors, banks, triggers, timers, objectives, text tags ...
Then, there are also some exceptions which could be referrences but are immutable, strings for example. Then there are even other types which are just "fake" types in gui and just represent ids in galaxy, for example dialogs and dialog items which are just ints in galaxy and therefore technically are no referrences, but then again they are indirectly because they just represent an id for an object managed by the game engine. So even though you are technically passing a copy to another function you can still modify the passed dialog or dialog item within it.
Might be useful to compile a list, but that would definatly require some effort and time.
@Mille25: Go
I have compiled a list about every type that the game supports (in the Galaxy language), it is here: https://github.com/midiway/Anion/wiki/Galaxy:-type-system
That chart can serve as a listing of every type supported by the game and its characteristics. But it doesn't identify this kind of types that have 'reference' semantics, f.e. trigger is 'reference' based, but it doesnt extends handle, as do the most of the handle types that surely are 'reference' types. I think we can name those types as 'complex types'. And as already noted, integers can also be complex types when they refer to dialogs, for example.
mid, Deaod has long since documented Galaxy, its Types, its Operators, and detailed instructions for using its Bitwise Operators.
Surely, I already knew those docs, though I forgot that they existed, but note that they are pretty old and mines are probably more correct/complete
I wrote my version of those charts just to make it more clear in order to help me write my Galaxy parser ...
Haha, sure, if you believe that the fundamental value types and operators that significant portions of the galaxy API depend upon would be changed ever, then I can see why you'd err in thinking Deaod's work could be outdated. Better still, by your own admission you assume the operator precedence table which you copied from your reference material on C, rather than actually test it, is more accurate than the table composed by the person who actually tested it.
This appears to be a case of rapidly-progressing acute NIH Syndrome.
Wow thats pretty cool! Should get a sticky if there isnt one yet. :)
@JademusSreg: Go you mad!!
I made those some time ago, and discussed many of my assumptions with Deaod himself, he told that he hasn't made many tests, and my chart would be more complete, I probably tested it more than he. So plz shut up.
Anyway, I didnt made it as the ultimate reference for Galaxy, It just some notes of what I need to know for making sure my parser is correct