Skip to content
Browse files

link spring:// under windows, too

  • Loading branch information...
1 parent 9f76caa commit c7fc5a3e3ee9ed02876d8c830e3faf7874b29617 jK committed Mar 27, 2014
Showing with 8 additions and 2 deletions.
  1. +8 −2 installer/sections/main.nsh
View
10 installer/sections/main.nsh
@@ -25,6 +25,12 @@
; please use this values directly without modifying them
WriteRegStr ${PRODUCT_ROOT_KEY} ${PRODUCT_KEY} "SpringEngineHelper" "$INSTDIR\unitsync.dll"
WriteRegStr ${PRODUCT_ROOT_KEY} ${PRODUCT_KEY} "SpringEngine" "$INSTDIR\spring.exe"
+
+ ; link custom spring:// scheme, so we can start spring from browser
+ WriteRegStr HKCR "spring" "" "URL:Spring Protocol"
+ WriteRegStr HKCR "spring" "URL Protocol" ""
+ WriteRegStr HKCR "spring\DefaultIcon" "" "spring.exe,1"
+ WriteRegStr HKCR "spring\shell\open\command" "" "$INSTDIR\spring.exe %1"
${EndIf}
!else
@@ -44,8 +50,8 @@
RmDir "$INSTDIR\games"
; Registry Keys
- DeleteRegValue ${PRODUCT_ROOT_KEY} ${PRODUCT_KEY} "SpringEngineHelper"
- DeleteRegValue ${PRODUCT_ROOT_KEY} ${PRODUCT_KEY} "SpringEngine"
+ DeleteRegKey ${PRODUCT_ROOT_KEY} ${PRODUCT_KEY}
+ DeleteRegKey HKCR "spring"
MessageBox MB_YESNO|MB_ICONQUESTION "Do you want me to completely remove all spring related files?$\n\
All maps, games, screenshots and your settings will be removed. $\n\

3 comments on commit c7fc5a3

@abma
Spring RTS member
abma commented on c7fc5a3 Mar 28, 2014

how does the correct version of spring start?

or whats the idea behind this? i guess i don't really understand the purpose. start spring from browser, yes, but some problems still exist:

  • used engine version has to be correct
  • map/game download is maybe needed

  • things we/i didn't think about yet

@jk3064
Spring RTS member
jk3064 commented on c7fc5a3 Mar 28, 2014
  1. You don't need to create a crappy text file anymore to connect as client to a host. It's the reason why I needed it for sync-debugging, so I was able to connect to the host just from bash w/o any script.txt . And it is the reason why lobby server & lobbies should switch in longterm, too. -> Uberserver should send just username, password, host, port (or just the url directly) in a cmd, and the lobby should then pass that to spring instead of any script.txt stuff with unknown content.
    Script.txt should absolutely be host only.

  2. @version: first I thought of mumble syntax like spring://host/?version=97, but then it's redundant data, it could just be put into the script.txt the host sends to the clients as it was once done in a patch made by zerver, that was reverted by kloot. Never the less multi-engine isn't what I want to implement atm.

  3. It simplifies how weblobbies can be done, also it allows to put links on websites you can use to connect as spectator to running matches. All a bit inspired by old UT99 days that already supported such custom url schemes.

  4. map/game downloading are another longterm want-to-have

@abma
Spring RTS member
abma commented on c7fc5a3 Mar 28, 2014

ok, thanks for explaining!

Please sign in to comment.
Something went wrong with that request. Please try again.