• 0

    posted a message on Making triangle region

    Is it possible to modify natives script now, like events?

    As far as I am aware it is not possible to modify natives like it is not possible to modify events as they are hard coded into the SC2 game engine.

    Posted in: Triggers
  • 0

    posted a message on AI melee don't start with all races

    I do not think the melee AI system was designed to cope with dynamically switching races.

     

    If setting the race and then turning on Melee AI does not work, you will need to use custom AI. This custom AI can use the melee AI logic (extract from the CASC system), however which functions it runs are dynamically resolved from race rather than a hard coded sequence for a specific race.

    Posted in: Triggers
  • 0.962722852512156

    posted a message on A number of questions about Trigger related issues

    3. Understanding what is a model and is not

    Any file ending with .dds is a texture. Any file ending with .m3 is a model. I think models reference textures at a specific file path within the StarCraft II file system. The hard coded texture paths can be swapped out with an arbitrary texture to some extent.

    5. How does one find the string for this highlighted action?

    UI editor allows one to browse the XML of the UI elements. The string is created based on what various XML elements are named.

    6. What does this do?

    Sets a global reference named "1testname" to the actor which executes the message. Another message can use this global reference to interact with that actor from another actor. Since the reference is global only 1 actor can be assigned to it at a time, however this is still useful if one only needs a reference to the actor immediately, eg for accompanying actor to connect to it. I think various targeting UI from WoL such as Raynor's Penetrating Rounds used global references. I also recall the heal beams from medic/medivac also using it.

    7. Talking Portraits(Lips)

    I think one needs to attach the appropriate lip sync file to the voice over that one orders the portrait to play. I am not familiar with how to load lip sync files to a portrait without a voice over, but possible they are animation extension files. Alarak and Zagara likely do not support lip sync (they have no human like mouth) so instead they use generic talking animations similar to how Warcraft III worked.

    Posted in: Triggers
  • 0.962236390387445

    posted a message on Not able to spawn unit : Error: Parameter ouf bounds in 'sUnitCreate' ...

    ...owner by 'any' = it's seem to make me the number of active player (and it doesn't give me any error)

    Any is not a valid parameter to make a unit with. A unit must be owned and any is not a valid owner.

     

    Parameter ouf bounds in 'sUnitCreate' (Value: 16, min: 0, max: 15) (this is what I don't know how to solve it)

    Player 16 is not a valid value for the player. I am guessing it is failing to find a unit so you are getting the owner of null and hence it returns an invalid player number.

    Posted in: Triggers
  • 0.96440489432703

    posted a message on [Net Neutrality] Asking the real question here.

    Why would they want to do such thing?

    Because half the reason a lot of people cannot play HotS in the USA is because of so many people streaming that it is overloading some internet nodes causing them to drop packets. Under current regulations all packets have to be dropped and delayed equally, even if that packet is 1 of several megabytes worth per second used for a 4k HD stream that no one would care is dropped, or is a few kilobytes per second of game command packets that is extremely latency critical and dropping it will cause the player to experience lag due to retransmission. Technically under the new regulations internet companies could offer cheaper low priority bandwidth for streaming companies where latency is unimportant but quantity is while offering game servers more expensive high priority bandwidth where latency is extremely important but quantity is small.

     

    Sounds good and sensible right? Well the problem, and reason why the previous regulation existed to stop this, is human greed. Instead of offering sensible QoS levels at sensible prices targeting different practical applications. They will use QoS to blackmail content providers into having to buy the most expensive "premium" QoS level to even stand a chance of having their packets delivered. Once everyone is subscribing to this premium QoS and the internet starts to behave like it does currently due to too much data and too little infrastructure they will then introduce a new "ultra premium" QoS level that is above "premium" with a larger cost. The black mail cycle will repeat with normal premium customers not being able to reliably deliver content unless they subscribe to the new ultra premium service. During this cycle no one bothers to invest in new infrastructure as you can just charge infinitely more for existing infrastructure by inventing new "extra ultra premium" QoS levels for it to sell.

     

    Mostly when they want to sell you a service and there is a free alternative out there, without net neutrality they can just block all access to it to users using their internet. It also enables them selling limited internet where you can only access certain things, which might not be terrible on individual level (as you chose to pay less) but is a bad thing on a bigger scale.

    The average private internet consumer will probably not notice the change at all, even to their internet bill, as there is no real way or point to meter them. It is the content providers who will be paying for the QoS, and that QoS can apply both ways (so they can pay for priority incoming and outgoing traffic). This is why Facebook, Google, etc are all against it since they will be the ones having to pay.

     

    What the average private internet consumer will notice is that the QoS of the sites they visit and services they use will change, for better or worse. In the case of games, if the game company subscribes to a higher end QoS connection then their players might have a better play experience as connections that lagged before start to work with low ping. On the other hand if the game company goes with the cheapest QoS they can find the opposite can happen and where as before players could play with low ping suddenly the game becomes unplayable. This can only be made worse if huge bandwidth intensive content providers such as Netflix or Google use high end QoS to deliver their streaming services as although their streaming performance might improve slightly, it will totally trash peoples ability to play online games unless the companies use the same or better QoS in which case it becomes nothing better than it is now but costing more.

     

    This is why "net neutrality" is important. This is why most sensible countries enforce it.

    Posted in: General Chat
  • 0

    posted a message on Ordering workers to build structures via triggers.

    You send it a build order to the desired location. Note it will fail if the location is not suitable for the build order, such as the building cannot be placed there or enemies are in the way.

     

    Be aware that in GUI the action to send orders to units defaults with an order function for instant orders. One needs to change this order function from the tree view to the appropriate order function that can allow a building order.

     

    If the player is AI controlled one can enable the AI for it and then send AI build orders. These are not really recommended for cinematics as the AI might not produce consistent results with them, and can even ignore them entirely.

    Posted in: Triggers
  • 0

    posted a message on Forcing AI to Build a Base and Train Units

    Be aware that AI train/build/upgrade orders should be periodically re-issued. The AI might otherwise forget them after a long time. This is how the melee AI works, it periodically clears the order queue and repopulates it with new orders.

    Posted in: AI Development
  • 0

    posted a message on Text when specific player joins the game

    Each account has a unique player handle. All you do is string comparison that handle with hard coded player handle strings for the appropriate players.

     

    That said it is generally considered bad mapping practice to do this outside of map developer only debug features.

    Posted in: Triggers
  • 0

    posted a message on Triggers, probability system variable! Help!

    For a start SC2 uses Galaxy not Jass (the trigger language of WC3).

    Technically both StarCraft (original, 1) and Warcraft III use JASS.

     

    One way to implement this is to use a 2D array where one index is for spawn types and the other index is for player. The sum of all unit type indices for a single player equals 100. To determine what to spawn pick a random integer between 1 and 100 (100 different possibilities). Loop through each unit type index for the player and add its chance value to an accumulator. If that accumulator is greater than or equal to the random integer that was rolled then spawn the unit (or save it to a variable to be spawned outside the loop) and break out the loop.

     

    This works for integer probabilities and technically can even work for totals not equal to 100 as long as the appropriate random number range is used.

     

    A more scaleable implementation would use a binary search tree to resolve which result occurred for the random number generated however for your use case a linear search should be sufficient.

    Posted in: Triggers
  • 0

    posted a message on How do you check the amount of resources, units, upgrades, etc. a player currently has?

    Why can't i use the Catalog Field Value Get As Integer action for units, the same as i used it for Upgrades? When i use this action, i simply cannot use the "Triggering Unit" in the "Entry" part. Does anyone know why this is the case? Also is there another way to get the values of the Units Data Catalog (especcially the CUnit_ScoreMake Value)?

    Its because a unit is not a unit catalog entry... You need to get the type of the unit which is a unit catalog entry.

     

    Technically speaking a unit is a unit where as a catalog entry is a string, hence incompatible type. You need to get the unit type of the unit which is a string and use that as a catalog entry.

     

    One can look at unspent resources directly as it is a player property.

    Posted in: Triggers
  • 0

    posted a message on How do you check the amount of resources, units, upgrades, etc. a player currently has?

    One can use catalog functions to dynamically look up the costs of an upgrade type or unit type. Instead of iterating through every upgrade declared to find which the player has, it might be more efficient to log upgrades in response to research complete events.

     

    StarCraft II might have events that allow logging of when player resources change, allowing one to track earnings and discard expenditure.

    Posted in: Triggers
  • 0

    posted a message on Cooldown reduce bug

    Sigh, People really need to read patch notes...

     

    Some time in the past year or two Blizzard standardized the display of time in StarCraft II to be real time, instead of game time. This was to avoid the nonsense of SC2 seconds being significantly faster than real seconds. Since all games are played at fastest game speed, the game time advances faster than real time. For that reason all times in the UI are reduced appropriately, so that they follow real time. If one was to alter the game speed dynamically, eg with triggers, then the timings on the UI should change appropriately. If game speed is set to slow then game time passes slower than real time so the numbers would (should...) be bigger.

     

    One can technically solve this by setting the map speed to standard (~16 game frames per second). The speed and timings of everything can be adjusted accordingly so that the overall game progression speed remains the same.

    Posted in: Data
  • 0

    posted a message on Star Battle Map Rewrite

    You can export the script from the existing map file and reuse large parts of it. Only triggers that have to be changed might need to be rewritten in GUI, unless you want to maintain them in Galaxy directly.

    Posted in: Triggers
  • 0

    posted a message on Is it possible to convert a galaxy.script to trigger language?

    The approach I would suggest is to use the galaxy script as galaxy script until you actively need to maintain it, in which case you remake that part in triggers.

     

    Galaxy script follows a C like style, especially if auto generated from GUI. Most lines translate directly into a GUI event/condition/action line.

    Posted in: Galaxy Scripting
  • 0

    posted a message on Attack method question

    Um then Is there any way to change the visuals or remove the missles and make it direct damage except changing the weapon? 

    One can remove the missile by removing the missile effect from the weapon effect chain. Instead of the weapon effect chain running the missile effect which then runs the missile effect impact effect (usually damage) on missile impact, one can replace the effect link for the missile effect directly with the missile effect impact effect link. This sounds complicated but basically it is cutting out the missile effect so that the damage is done instantly.

     

    If one wants the missiles to still exist but move faster then modify the missile mover so that it has higher acceleration, max speed, initial speed, etc. Be aware that engine limitations may mean that really high values still take a few frames to impact, however this considerably faster than any missile used in melee play.

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