LIBRARY "Storm"

EXPORTS
    ; Networking
    ;SNetCreateGame                @101 NONAME
    ;SNetDestroy                   @102 NONAME
    ;SNetEnumDevices               @103 NONAME
    ;SNetEnumGames                 @104 NONAME
    ;SNetEnumProviders             @105 NONAME
    ;SNetDropPlayer                @106 NONAME
    ;SNetGetGameInfo               @107 NONAME
    ;SNetGetNetworkLatency         @108 NONAME
    ;SNetGetNumPlayers             @109 NONAME
    ;SNetGetOwnerTurnsWaiting      @110 NONAME
    ;SNetGetPerformanceData        @111 NONAME
    ;SNetGetPlayerCaps             @112 NONAME
    ;SNetGetPlayerName             @113 NONAME
    ;SNetGetProviderCaps           @114 NONAME
    ;SNetGetTurnsInTransit         @115 NONAME
    ;SNetInitializeDevice          @116 NONAME
    ;SNetInitializeProvider        @117 NONAME
    ;SNetJoinGame                  @118 NONAME
    ;SNetLeaveGame                 @119 NONAME
    ;SNetPerformUpgrade            @120 NONAME
    ;SNetReceiveMessage            @121 NONAME
    ;SNetReceiveTurns              @122 NONAME
    ;SNetRegisterEventHandler      @123 NONAME
    ;SNetResetLatencyMeasurements  @124 NONAME
    ;SNetSelectGame                @125 NONAME
    ;SNetSelectProvider            @126 NONAME
    ;SNetSendMessage               @127 NONAME
    ;SNetSendTurn                  @128 NONAME
    ;SNetSetBasePlayer             @129 NONAME
    ;SNetSetGameMode               @130 NONAME
    ;SNetUnregisterEventHandler    @131 NONAME
    ;SErrSetBlizzardErrorFunction  @132   ; SNetGetOwnerId in SC beta and Diablo/Hellfire, something else in WC3 1.0.7+
    ;SNetEnumGamesEx               @133 NONAME
    ;SNetSendServerChatCommand     @134 NONAME
    ;SNetSendDatagram              @135 NONAME
    ;SNetReceiveDatagram           @136 NONAME
    ;SNetDisconnectAll             @137 NONAME
    ;SNetCreateLadderGame          @138 NONAME
    ;SNetReportGameResult          @139 NONAME
    ;SNetCheckDataFile             @140 NONAME

    ; Networking (League/Extended) - These are all different in WC3 1.0.7+
    ;SNetSendLeagueCommand         @141 NONAME
    ;SNetSendReplayPath            @142 NONAME
    ;SNetGetLeagueId               @143 NONAME
    ;SNetGetPlayerNames            @144 NONAME
    ;SNetLeagueLogout              @145 NONAME
    ;SNetGetReplyName              @146 NONAME
    ;SNetGetCurrentProviderID      @147 NONAME
    ;SNetSetCodeSignVerifcationFunction @148

    ; Dlg
    ;SDlgBeginPaint                @201 NONAME
    ;SDlgBltToWindowI              @202 NONAME
    ;SDlgCheckTimers               @203 NONAME
    ;SDlgCreateDialogIndirectParam @204 NONAME
    ;SDlgCreateDialogParam         @205 NONAME
    ;SDlgDefDialogProc             @206 NONAME
    ;SDlgDestroy                   @207 NONAME
    ;SDlgDialogBoxIndirectParam    @208 NONAME
    ;SDlgDialogBoxParam            @209 NONAME
    ;SDlgDrawBitmap                @210 NONAME
    ;SDlgEndDialog                 @211 NONAME
    ;SDlgEndPaint                  @212 NONAME
    ;SDlgKillTimer                 @213 NONAME
    ;SDlgSetBaseFont               @214 NONAME
    ;SDlgSetBitmapI                @215 NONAME
    ;SDlgSetControlBitmaps         @216 NONAME
    ;SDlgSetCursor                 @217 NONAME
    ;SDlgSetSystemCursor           @218 NONAME
    ;SDlgSetTimer                  @219 NONAME
    ;SDlgUpdateCursor              @220 NONAME
    ;SDlgBltToWindowE              @221 NONAME
    ;SDlgSetBitmapE                @222 NONAME
    ;SDlgSetLocale                 @223 NONAME
    ;SDlgSetMessageLoopThrottle    @224 NONAME
    ;SDlgClearWindowMap            @225 NONAME
    ;SDlgResetWindowPos            @226 NONAME
    ;SDlgAddWindowToMap            @227 NONAME
    ;SDlgRemoveWindowFromMap       @228 NONAME
    ;SDlgAdjustWindowsToParent     @229 NONAME
    ;SDlgTakeScreenshot            @230 NONAME

    ; File
    ;SFileAuthenticateArchive      @251 NONAME
    ;SFileCloseArchive             @252 NONAME
    ;SFileCloseFile                @253 NONAME
    ;SFileDdaBegin                 @254 NONAME
    ;SFileDdaBeginEx               @255 NONAME
    ;SFileDdaDestroy               @256 NONAME
    ;SFileDdaEnd                   @257 NONAME
    ;SFileDdaGetPos                @258 NONAME
    ;SFileDdaGetVolume             @259 NONAME
    ;SFileDdaInitialize            @260 NONAME
    ;SFileDdaSetVolume             @261 NONAME
    ;SFileDestroy                  @262 NONAME
    ;SFileEnableDirectAccess       @263 NONAME
    ;SFileGetFileArchive           @264 NONAME
    ;SFileGetFileSize              @265 NONAME
    ;SFileOpenArchive              @266 NONAME
    ;SFileOpenFile                 @267 NONAME
    ;SFileOpenFileEx               @268 NONAME
    ;SFileReadFile                 @269 NONAME
    ;SFileSetBasePath              @270 NONAME
    ;SFileSetFilePointer           @271 NONAME
    ;SFileSetLocale                @272 NONAME
    ;SFileGetBasePath              @273 NONAME
    ;SFileSetIoErrorMode           @274 NONAME
    ;SFileGetArchiveName           @275 NONAME
    ;SFileGetFileName              @276 NONAME
    ;SFileGetArchiveInfo           @277 NONAME
    ;SFileSetPlatform              @278 NONAME
    ;SFileLoadFile                 @279 NONAME
    ;SFileUnloadFile               @280 NONAME
    ;SFileLoadFileEx               @281 NONAME
    ;SFilePrioritizeRequest        @282 NONAME
    ;SFileCancelRequest            @283 NONAME
    ;SFileSetAsyncBudget           @284 NONAME
    ;SFileSetDataChunkSize         @285 NONAME
    ;SFileEnableSeekOptimization   @286 NONAME
    ;SFileReadFileEx               @287 NONAME
    ;SFileFileExists               @288 NONAME
    ;SFileFileExistsEx             @289 NONAME
    ;SFileReadFileEx2              @290 NONAME
    ;SFileReadFile2                @291 NONAME
    ;SFileLoadFile2                @292 NONAME
    ;SFileOpenFileAsArchive        @293 NONAME
    ;SFileGetLocale                @294 NONAME
    ;SFileGetInstallPath           @295 NONAME  ; SFileRegisterLoadNotifyProc in WC3
    ;SFileGetUserDataPath          @296 NONAME  ; SFileGetFileCompressedSize in WC3
    ;SFileSetUserDataPath          @297 NONAME  ; different in WC3
    ;SFileAuthenticateArchiveEx    @299 NONAME
    ;SFileOpenPathAsArchive        @300 NONAME

    ; Main
    ; This is the only *Destroy function exported, tests will need to use it instead
    StormDestroy                   @301 NONAME
    ;StormGetInstance              @302 NONAME
    ;StormGetOption                @303 NONAME
    ;StormSetOption                @304 NONAME

    ; Blit
    ;SBltDestroy                   @311 NONAME
    ;SBltGetSCode                  @312 NONAME
    ;SBltROP3                      @313 NONAME
    ;SBltROP3Clipped               @314 NONAME
    ;SBltROP3Tiled                 @315 NONAME

    ; BMP
    ;SBmpDecodeImage               @321 NONAME
    ;SBmpLoadImage                 @323 NONAME
    ;SBmpSaveImage                 @324 NONAME
    ;SBmpAllocLoadImage            @325 NONAME
    ;SBmpSaveImageEx               @326 NONAME
    ;SBmpPadImage                  @327 NONAME
    ;SBmpGetPitchForAlignment      @328 NONAME

    ; SCode
    ;SCodeCompile                  @331 NONAME
    ;SCodeDelete                   @332 NONAME
    ;SCodeDestroy                  @333 NONAME
    ;SCodeExecute                  @334 NONAME
    ;SCodeGetPseudocode            @335 NONAME

    ; Draw
    ;SDrawAutoInitialize           @341 NONAME
    ;SDrawCaptureScreen            @342 NONAME
    ;SDrawClearSurface             @343 NONAME  ; SDrawCaptureGDIScreen in SC 1.17
    ;SDrawDestroy                  @344 NONAME  ; SDrawClearSurface in SC 1.17
    ;SDrawFlipPage                 @345 NONAME  ; SDrawDestroy in SC 1.17
    ;SDrawGetFrameWindow           @346 NONAME
    ;SDrawGetObjects               @347 NONAME
    ;SDrawGetScreenSize            @348 NONAME
    ;SDrawGetServiceLevel          @349 NONAME  ; SDrawFlush in SC 1.17
    ;SDrawLockSurface              @350 NONAME
    ;SDrawManualInitialize         @351 NONAME  ; SDrawInitialize in SC 1.17
    ;SDrawMessageBox               @352 NONAME
    ;SDrawPostClose                @353 NONAME
    ;SDrawRealizePalette           @354 NONAME
    ;SDrawSelectGdiSurface         @355 NONAME
    ;SDrawUnlockSurface            @356 NONAME
    ;SDrawUpdatePalette            @357 NONAME
    ;SDrawUpdateScreen             @358 NONAME
    ;SDrawWaitForVerticalBlank     @359 NONAME

    ; Event
    ;SEvtDestroy                   @371 NONAME
    SEvtDispatch                  @372 NONAME
    SEvtRegisterHandler           @373 NONAME
    SEvtUnregisterHandler         @374 NONAME
    SEvtUnregisterType            @375 NONAME
    SEvtPopState                  @376 NONAME
    SEvtPushState                 @377 NONAME
    SEvtBreakHandlerChain         @378 NONAME

    ; GDI
    ;SGdiBitBlt                    @381 NONAME
    ;SGdiCreateFont                @382 NONAME
    ;SGdiDeleteObject              @383 NONAME
    ;SGdiDestroy                   @384 NONAME
    ;SGdiExtTextOut                @385 NONAME
    ;SGdiImportFont                @386 NONAME
    ;SGdiLoadFont                  @387 NONAME
    ;SGdiRectangle                 @388 NONAME
    ;SGdiSelectObject              @389 NONAME
    ;SGdiSetPitch                  @390 NONAME
    ;SGdiTextOut                   @391 NONAME
    ;SGdiSetTargetDimensions       @392 NONAME
    ;SGdiGetTextExtent             @393 NONAME

    ; Memory
    SMemAlloc                     @401 NONAME
    ;SMemDestroy                   @402 NONAME
    SMemFree                      @403 NONAME
    ;SMemGetSize                   @404 NONAME
    SMemReAlloc                   @405 NONAME
    ;SMemGetAllocated              @406 NONAME

    ; Message handling
    ;SMsgDestroy                   @411 NONAME
    ;SMsgDispatchMessage           @412 NONAME
    ;SMsgDoMessageLoop             @413 NONAME
    ;SMsgRegisterCommand           @414 NONAME
    ;SMsgRegisterKeyDown           @415 NONAME
    ;SMsgRegisterKeyUp             @416 NONAME
    ;SMsgRegisterMessage           @417 NONAME
    ;SMsgPopRegisterState          @418 NONAME
    ;SMsgPushRegisterState         @419 NONAME
    ;SMsgRegisterSysCommand        @420 NONAME

    ; Registry
    ;SRegLoadData                  @421 NONAME
    ;SRegLoadString                @422 NONAME
    ;SRegLoadValue                 @423 NONAME
    ;SRegSaveData                  @424 NONAME
    ;SRegSaveString                @425 NONAME
    ;SRegSaveValue                 @426 NONAME
    ;SRegGetBaseKey                @427 NONAME
    ;SRegDeleteValue               @428 NONAME
    ;SRegEnumKey                   @429 NONAME
    ;SRegGetNumSubKeys             @430 NONAME

    ; Transparency
    ;STransBlt                     @431 NONAME
    ;STransBltUsingMask            @432 NONAME
    ;STransCreateI                 @433 NONAME
    ;STransDelete                  @434 NONAME
    ;STransDestroy                 @435 NONAME
    ;STransDuplicate               @436 NONAME
    ;STransIntersectDirtyArray     @437 NONAME
    ;STransInvertMask              @438 NONAME
    ;STransLoadI                   @439 NONAME
    ;STransSetDirtyArrayInfo       @440 NONAME
    ;STransUpdateDirtyArray        @441 NONAME
    ;STransIsPixelInMask           @442 NONAME
    ;STransCombineMasks            @443 NONAME
    ;STransCreateMaskI             @444 NONAME
    ;STransCreateE                 @445 NONAME
    ;STransCreateMaskE             @446 NONAME
    ;STransLoadE                   @447 NONAME

    ; Video
    ;SVidDestroy                   @451 NONAME
    ;SVidGetSize                   @452 NONAME
    ;SVidInitialize                @453 NONAME
    ;SVidPlayBegin                 @454 NONAME
    ;SVidPlayBeginFromMemory       @455 NONAME
    ;SVidPlayContinue              @456 NONAME
    ;SVidPlayContinueSingle        @457 NONAME
    ;SVidPlayEnd                   @458 NONAME
    ;SVidSetVolume                 @459 NONAME

    ; Error
    ;SErrDestroy                   @460 NONAME
    SErrDisplayError              @461 NONAME
    ;SErrGetErrorStr               @462 NONAME
    SErrGetLastError              @463 NONAME
    ;SErrRegisterMessageSource     @464 NONAME
    ;SErrSetLastError              @465 NONAME
    ;SErrReportNamedResourceLeak   @466 NONAME
    ;SErrReportResourceLeak        @467 NONAME
    SErrSuppressErrors            @468 NONAME
    ;SErrRegisterHandler           @469 NONAME
    ;SErrUnregisterHandler         @470 NONAME

    ; Command line
    ;SCmdGetBool                   @472 NONAME
    ;SCmdGetNum                    @473 NONAME
    ;SCmdGetString                 @474 NONAME
    ;SCmdProcess                   @475 NONAME
    ;SCmdRegisterArgList           @476 NONAME
    ;SCmdRegisterArgument          @477 NONAME
    ;SCmdCheckId                   @478 NONAME
    ;SCmdProcessCommandLine        @479 NONAME
    ;SCmdStringExists              @480 NONAME

    ; Memory extended
    ;SMemFindNextBlock             @481 NONAME
    ;SMemFindNextHeap              @482 NONAME
    ;SMemGetHeapByCaller           @483 NONAME
    ;SMemGetHeapByPtr              @484 NONAME
    ;SMemHeapAlloc                 @485 NONAME
    ;SMemHeapCreate                @486 NONAME
    ;SMemHeapDestroy               @487 NONAME
    ;SMemHeapFree                  @488 NONAME
    ;SMemHeapRealloc               @489 NONAME
    ;SMemHeapSize                  @490 NONAME
    SMemCopy                      @491 NONAME
    SMemFill                      @492 NONAME
    SMemMove                      @493 NONAME
    SMemZero                      @494 NONAME
    SMemCmp                       @495 NONAME
    ;SMemSetDebugFlags             @496 NONAME
    ;SMemDumpState                 @497 NONAME

    ; Strings
    SStrCopy                      @501 NONAME
    SStrHash                      @502 NONAME
    SStrPack                      @503 NONAME
    SStrTokenize                  @504 NONAME
    ;SStrChrBidir                 @505 NONAME
    SStrLen                       @506 NONAME
    SStrDupA                      @507 NONAME
    SStrCmp                       @508 NONAME
    SStrCmpI                      @509 NONAME
    SStrUpper                     @510 NONAME

    ; Messages extended
    ;SMsgBreakHandlerChain         @511 NONAME
    ;SMsgUnregisterCommand         @512 NONAME
    ;SMsgUnregisterKeyDown         @513 NONAME
    ;SMsgUnregisterKeyUp           @514 NONAME
    ;SMsgUnregisterMessage         @515 NONAME
    ;SMsgGetGenericWndProc         @516 NONAME
    ;SMsgSetDefaultWindow          @517 NONAME
    ;SMsgGetDefaultWindow          @518 NONAME
    ;SMsgUnregisterSysCommand      @519 NONAME

    ; Regions
    SRgnClear                     @521 NONAME
    SRgnCombineRecti              @523 NONAME
    SRgnCreate                    @524 NONAME
    SRgnDelete                    @525 NONAME
    ;SRgnDestroy                   @526 NONAME
    SRgnDuplicate                 @527 NONAME
    SRgnGetRectParamsi            @528 NONAME
    SRgnGetRectsi                 @529 NONAME
    SRgnGetBoundingRecti          @530 NONAME
    SRgnIsPointInRegioni          @531 NONAME
    SRgnIsRectInRegioni           @532 NONAME
    SRgnOffseti                   @533 NONAME
    SRgnCombineRectf              @534 NONAME
    SRgnGetRectParamsf            @535 NONAME
    SRgnGetRectsf                 @536 NONAME
    SRgnGetBoundingRectf          @537 NONAME
    SRgnIsPointInRegionf          @538 NONAME
    SRgnIsRectInRegionf           @539 NONAME
    SRgnOffsetf                   @540 NONAME

    ; Logging
    ;SLogClose                     @541 NONAME
    ;SLogCreate                    @542 NONAME
    ;SLogSetTimestamp              @543 NONAME
    ;SLogDump                      @544 NONAME
    ;SLogFlush                     @545 NONAME
    ;SLogFlushAll                  @546 NONAME
    ;SLogPend                      @547 NONAME
    ;SLogWrite                     @548 NONAME
    ;SLogSetAbsIndent              @549 NONAME
    ;SLogSetIndent                 @550 NONAME

    ; Compression
    ;SCompCompress                 @551 NONAME
    ;SCompDecompress               @552 NONAME

    ; Errors extended
    ;SLogVWrite                    @553 NONAME
    SErrDisplayAppFatal           @561 NONAME
    SErrDisplayErrorFmt           @562 NONAME
    ;SErrIsDisplayingError         @563 NONAME
    SErrPrepareAppFatal           @564 NONAME
    ;SErrSetLogTitleString         @565 NONAME
    ;SErrCheckDebugSymbolLibrary   @566 NONAME
    ;SErrCatchUnhandledExceptions  @567 NONAME
    ;SErrSetLogCallback            @568 NONAME

    ; Strings extended
    ;?SStrChr@@YGPADPADD@Z         @569 NONAME  ; Not offered in SC 1.17
    ;?SStrChrR@@YGPADPADD@Z        @570 NONAME  ; Not offered in SC 1.17
    ?SStrChr@@YGPBDPBDD@Z         @571 NONAME
    ?SStrChrR@@YGPBDPBDD@Z        @572 NONAME
    SStrToDouble                  @573 NONAME
    SStrToFloat                   @574 NONAME
    SStrToInt                     @575 NONAME
    SStrToUnsigned                @576 NONAME
    ;SStrToInt64                   @577 NONAME
    SStrPrintf                    @578 NONAME
    SStrLower                     @579 NONAME
    SStrHash64                    @580 NONAME
    SStrVPrintf                   @581 NONAME

    ; More drawing
    ;SMsgSetDefaultWindowRect      @582 NONAME
    ;SMsgGetDefaultWindowRect      @583 NONAME

    ; More strings
    ?SStrStr@@YGPADPADPBD@Z       @584 NONAME
    ?SStrStr@@YGPBDPBD0@Z         @585 NONAME
    ?SStrStrI@@YGPADPADPBD@Z      @586 NONAME
    ?SStrStrI@@YGPBDPBD0@Z        @587 NONAME

    ;SysQueueUserEvent            @588 NONAME   ; SStrStr in WC3
    ;SStrHashHT                    @595 NONAME  ; Not offered in SC 1.17

    ; Big numbers
    SBigAdd                       @601 NONAME
    SBigAnd                       @602 NONAME
    SBigCompare                   @603 NONAME
    SBigCopy                      @604 NONAME
    SBigDec                       @605 NONAME
    SBigDel                       @606 NONAME
    SBigDiv                       @607 NONAME
    ;SBigFindPrime                 @608 NONAME
    SBigFromBinary                @609 NONAME
    SBigFromStr                   @610 NONAME
    ;SBigFromStream                @611 NONAME
    SBigFromUnsigned              @612 NONAME
    ;SBigGcd                       @613 NONAME
    SBigInc                       @614 NONAME
    ;SBigInvMod                    @615 NONAME
    SBigIsEven                    @616 NONAME
    SBigIsOdd                     @617 NONAME
    SBigIsOne                     @618 NONAME
    ;SBigIsPrime                   @619 NONAME
    SBigIsZero                    @620 NONAME
    SBigMod                       @621 NONAME
    SBigMul                       @622 NONAME
    ;SBigMulMod                    @623 NONAME
    SBigNew                       @624 NONAME
    SBigNot                       @625 NONAME
    SBigOr                        @626 NONAME
    ;SBigPow                       @627 NONAME
    SBigPowMod                    @628 NONAME
    ;SBigRand                      @629 NONAME
    ;SBigSet2Exp                   @630 NONAME
    ;SBigSetOne                    @631 NONAME
    ;SBigSetZero                   @632 NONAME
    SBigShl                       @633 NONAME
    SBigShr                       @634 NONAME
    SBigSquare                    @635 NONAME
    SBigSub                       @636 NONAME
    ;SBigToBinaryArray             @637 NONAME
    SBigToBinaryBuffer            @638 NONAME
    ;SBigToBinaryPtr               @639 NONAME
    ;SBigToStrArray                @640 NONAME
    ;SBigToStrBuffer               @641 NONAME
    ;SBigToStrPtr                  @642 NONAME
    ;SBigToStreamArray             @643 NONAME
    ;SBigToStreamBuffer            @644 NONAME
    ;SBigToStreamPtr               @645 NONAME
    SBigToUnsigned                @646 NONAME
    SBigXor                       @647 NONAME

    ; Unicode
    ;SUniConvertUTF16to8Len        @901 NONAME
    ;SUniConvertUTF16to8           @902 NONAME
    ;SUniConvertUTF8to16Len        @903 NONAME
    ;SUniConvertUTF8to16           @904 NONAME
    SUniSGetUTF8                  @905 NONAME
    SUniSPutUTF8                  @906 NONAME
    ;SUniFindAfterUTF8Chr          @907 NONAME
    ;SUniFindUTF8ChrStart          @908 NONAME
    ;SUniConvertUTF16ToWin         @909 NONAME
    ;SUniConvertUTF16ToMac         @910 NONAME
    ;SUniConvertUTF16ToDos         @911 NONAME
    ;SUniConvertWinToUTF16         @912 NONAME
    ;SUniConvertMacToUTF16         @913 NONAME
    ;SUniConvertDosToUTF16         @914 NONAME
    ;SUniConvertUTF8ToWin          @915 NONAME

