• 0

    posted a message on Some Galaxy Discoveries

    @Deaod: Go

    Oh, right. Oops.

    Posted in: Galaxy Scripting
  • 0

    posted a message on Some Galaxy Discoveries
    Quote from Mexaprone: Go

    @Deaod: Go Bools have the same size as a byte.

    This is true down to the assembly. Bools are treated as bytes because it is faster to pass them around that way (no bit fiddling). 1 is true and not 1 is false.

    Posted in: Galaxy Scripting
  • 0

    posted a message on Are Linked Lists Possible?

    Using arrays means you have to allocate the data before hand, and there is no creation/release for that so you use more memory. Of course, you're trading less memory for more operations to get to your data. If you already know your maximum limit, then arrays work too. Also, it's the same at the system level, so the array index is your pointer.

    I think WEU and newgenpack for war3 used arrays and syntactic sugar for structs, and that works out okay, so... eh.

    Posted in: Galaxy Scripting
  • 0

    posted a message on Are Linked Lists Possible?

    Has anyone figured if they can get functioning linked lists?

    I think this might work but it's really sketchy. It uses dialogs and the link is implicit via built-in functions to get the next node.

    Pardon my ignorance if this code is wrong or has been tried before. I know most calls missing parameters. I've not been coding in galaxy for a while.

    int head = DialogCreate();
    int first = head;
    int curr;
    int j;
    for (int i = 0; i < 10; i++)
    {
        curr = DialogCreate();
        DialogSetChannel(curr, i);
        DialogSetPositionRelative(head, curr);
        head = curr;
    }
    curr = head;
    while (curr != first)
    {
        UIDisplayMessage(PlayerGroupActive(), 0, StringToText(IntToString(DialogGetChannel(curr))));
        curr = DialogGetRelativeDialog(curr);
    }
    
    Posted in: Galaxy Scripting
  • 0

    posted a message on Galaxy++ editor

    I don't know if this is an active project but I see the last post is 21 hours ago. I also don't know if this has already been done. Would it be possible to add generic functions?

    void PerformCleanup<T>(T item)
    {
        // cleanup
        SetState(item.state, 0);
        // etc.
    }
    
    // call it
    PerformCleanup<MyStruct>(structA);
    

    Not sure if that would be helpful but I assume a simple static generic function would be good to have. I don't think it would be harder to code than what you have currently done.

    Posted in: Third Party Tools
  • 0

    posted a message on Changing Unit Skin With Ability/Upgrade?

    I was playing the Cortex RP and one upgrade changed the skin for some Protoss units to sleek black. How do I accomplish this? Is it just data or do I have to make prefab skin textures and just change the attribute for the texture?

    Posted in: Miscellaneous Development
  • 0

    posted a message on "Unable to load dependency"?

    When trying to open a map with some custom dependency, it will say something like "Unable to load dependencies. Would you like to run the repair tool?"

    How do I fix this?

    Posted in: Miscellaneous Development
  • 0

    posted a message on [Data] Unit Afterimage Effect

    Somebody has to have a video on ultra in HD.

    Posted in: Tutorials
  • 0

    posted a message on [WIP] Line Tower Wars

    @DarkRevenantX: Go

    Heh.

    @Sevenation: Go

    Seven, it's all about speed. I'm sure you can time these functions separately. Also, I don't think he was being an ass. There is a function that can do that for you so I think it'll be faster than the algorithm you use now.

    Posted in: Project Workplace
  • 0

    posted a message on Triggers still broken

    You can attach an event in-game, but I don't think you can remove events. It's still sad because even after WarCraft III, you still can't remove events.

    You can destroy the trigger, create a new one, attach a new event, and attach all the same conditions and actions, and there you go. You now have a trigger with a dynamic event. I wouldn't recommend doing this very often, because it could lag a game up if it was, say, on a timer of 0.1 seconds.

    Posted in: Miscellaneous Development
  • 0

    posted a message on Saving Map States

    You can't load and save map states. You would have to set up units and triggers conditionally. This worked alright for WarCraft III custom campaigns, in that the main action didn't really happen on the central map so it was easy to keep track of the state. The main map just kept track of the quests you completed, but you can probably store more information with banks now.

    Posted in: Galaxy Scripting
  • 0

    posted a message on [Library] STARCODE v1.4

    @s3rius: Go

    Also, what base is this stored in? 64? More?

    Posted in: Trigger Libraries & Scripts
  • 0

    posted a message on [Info] Patch 18 Undocumented Editor Changes

    What? Patch 18? Bull.

    Posted in: Galaxy Editor Bugs and Feedback
  • 0

    posted a message on Battle.net updates for the download of SC2 client~

    @Kanaru Is that Browder in your helmet? Lol!

    Also sweet, do want full details when the game is cracked.

    Posted in: General Chat
  • 0

    posted a message on Netstorm: Islands at War

    @depthsofchaos: Go You can "lock" a map. I've never actually tested what a locked map is, but it might encode the trigger file or even the entire .mpq. Also, I think you can convert text to a string.

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