• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[Crash] No war3 CD inserted?! O_o

Status
Not open for further replies.
When I was developing another system for OaD, I've found extremely weird issue connected with region type.
So, here is the code I did:
JASS:
scope GeneralInit initializer Init
    globals
        region Desert_InnerBase = CreateRegion()
        region Oasis_InnerBase  = CreateRegion()
    endglobals
    
    private function Init takes nothing returns nothing
        // Desert Inner Base
        call RegionAddRect(Desert_InnerBase,gg_rct_DesInnerBase)
        call RegionAddRect(Desert_InnerBase,gg_rct_DesInner1)
        call RegionAddRect(Desert_InnerBase,gg_rct_DesInner2)
        call RegionAddRect(Desert_InnerBase,gg_rct_DesInner3)
        call RegionAddRect(Desert_InnerBase,gg_rct_DesInner4)
        call RegionAddRect(Desert_InnerBase,gg_rct_DesInner5)
        call RegionAddRect(Desert_InnerBase,gg_rct_DesInner6)
        // Oasis Inner Base
        call RegionAddRect(Oasis_InnerBase,gg_rct_OasInnerBase)
        call RegionAddRect(Oasis_InnerBase,gg_rct_OasInner1)
        call RegionAddRect(Oasis_InnerBase,gg_rct_OasInner2)
        call RegionAddRect(Oasis_InnerBase,gg_rct_OasInner3)
    endfunction
endscope

I just wanted to register inner base rects for my map. But here is what happened: during World Editor map test, during the map loading, 'please insert war3 cd' window appeared. I've pressed 'continue' and voila! Fatal error.
Just one word: dat blizzards :p
 
Level 22
Joined
Sep 24, 2005
Messages
4,821
Try initializing the region handles on the Initialization function. I think the crash is caused by initializing it on the global declaration.
 
Status
Not open for further replies.
Top