Author Topic: Poor man's PXO  (Read 5323 times)

0 Members and 1 Guest are viewing this topic.

Offline Inquisitor

NOTE: This all works EXCEPT making the hash table on start.  Run "/makelistservers" after the script loads to create the hash table.

_____________
Using mIRC.

Open mIRC and connect to the maxgaming irc server. If you don;t have miRC, get a custom version at: http://www.mgonetwork.com/downloads2.php

You want "MGOmIRC Version 2"

Create a file called fs2scraper.mrc in mgogames in your mirc install folder.
Quote

; Open a custom window called @IRC when mIRC starts
;on *:START: hmake FS2Games 50
on *:START: window @FS2ServerLog
;on *:START: clearlistservers

; If the user tries to close @IRC, open it again
; This is a kludge but unfortunately it's hard to come up with a better solution
on *:CLOSE:@FS2ServerLog: .timer 1 0 window @FS2ServerLog

; Since $network doesn't always return value, use $server for the network name if $network fails
alias -l networkname {
if ( $network ) return $network
return $server
}

alias listservers {
var %lcv
; declare the loop control variable as local, this will clean it up
; automatically when the alias is finished executing

%lcv = 1
; set the initial value of the lcv to 1, we start at the first nickname
echo @FS2ServerLog Host Nickname ---- Host IP Address
while (%lcv <= $hget(FS2Games,0).item) {


SET %HostNick $hget(FS2Games,%lcv).item
SET %HostIP $hget(FS2Games,%HostNick)
;echo @FS2ServerLog Host Nickname ---- Host IP Address
echo @FS2ServerLog %HostNick ---- %HostIP
; echo -a Nickname %lcv $+ : $nick(#, %lcv)
; we output the lcv'th nickname

inc %lcv
; we increment the lcv by one since so we can go to the next nickname
; since we have the condition to check the bounds of the lcv, once we have outputted
; the last nickname, the condition will become false and the loop will quit

}
; end the loop
}

alias clearlistservers {
hfree -s FS2games
hmake -s FS2Games 50
}

alias makelistservers {
hmake -s FS2Games 50
}

; Scan Channel messages

on *:TEXT:*FS2 Game started at IP*:#: {
SET %GameIP $6
; hmake FS2Games 50
hadd -s FS2Games $nick %GameIP
echo $color(normal text) -mlti2 @FS2ServerLog < $+ $networkname $+ : $+ $target $+ : $+ $nick $+ > $strip($1-,m)
echo @FS2ServerLog $hget(FS2Games,0).item Servers started since you logged on.
listservers
}


This scans the channels you are in for the text "FS2 Game started at IP"  and takes the 6th word in that string (which will be the IP address right after the word IP, see below). and sets it to %GameIP.

It then writes the players IRC nickname and %GameIP to a local hash table.

It also creates the command "/listservers" that will echo the contents of your hash table, which is simply is a list of all servers your client is aware of since mIRC was started (obviously this isn't scalable).

You want to load this script by entering:
Quote

/reload -rs mgogames/fs2scraper.mrc


Now-

Hit alt-p after you launch mIRC

Go to View-->Nickname List
at the botom of the text field, add the following including the "-" :

Quote

-
Freespace 2 GamePlay
.Start Server List:{/makelistservers }
.Clear Serever List:{/clearlistservers }
.List Servers:{/listservers }
.Join Manually FS2:{/run c:\games\freespace2\fs2_open.exe -connect $$?=Enter IP| /msg $chan 4 $me, Joining a game of Freespace2 }
.Join Selected Nick FS2:{/run c:\games\freespace2\fs2_open.exe -connect $hget(FS2Games, $+ $1) }
.Host FS2 Game:{/run c:\games\freespace2\fs2_open.exe -startgame | /msg $chan FS2 Game started at IP $IP }



What that does:
Adds a menu item called gameplay when you right-click in the channel user list pane. In Gameplay, you have 2 options, join a game in progress or host a game. If you right click on a username who has just launched a game, it will pop a dialog for you to manually enter the IP address of the host.

It also adds a menu item that lets you join a game hosted by the selected user, so highlighting the uername in mIRC, what that does is go to the hash table we created above, lookup the IP associated with that nick, and launches the game with the -connect argument.

Obviously you need to edit the path to wherever fs2 is installed, need to add a reg entry for install directory, then I'll be able to read it.

Next stop, a GUI that lists all the games your mIRC client knows about :) And managing the number of servers your client is aware of by age of the server :)
« Last Edit: November 17, 2002, 01:57:29 pm by 122 »
No signature.

 

Offline mikhael

  • Back to skool
  • 211
  • Fnord!
    • http://www.google.com/search?q=404error.com
Quite Groovy. :)
[I am not really here. This post is entirely a figment of your imagination.]

 

Offline Sesquipedalian

  • Atankharz'ythi
  • 211
This needs to be put somewhere permanetly accessible and highly visible.
Sesqu... Sesqui... what?
Sesquipedalian, the best word in the English language.

The Scroll of Atankharzim | FS2 syntax highlighting

 

Offline BlackDove

  • Star Killer
  • 211
  • Section 3 of the GTVI
    • http://www.shatteredstar.org
Well it works for me so far, we'll see about the game part soon :p

 

Offline Inquisitor

Yeah, I am behind on putting the site up, this will go on it :)

Anyone want to be a part time webmaster?
No signature.

 

Offline Taristin

  • Snipes
  • 213
  • BlueScalie
    • Skelkwank Shipyards
Now if only you could make it so the game did all this for you...
Freelance Modeler | Amateur Artist

 

Offline Stealth

  • Braiiins...
  • 211
Quote
Originally posted by Inquisitor
Yeah, I am behind on putting the site up, this will go on it :)

Anyone want to be a part time webmaster?


i can be a part time webmaster...

 

Offline Inquisitor

You have to respond to the email I sent ;) I  understand you volunteered to help caretake the tester list.

Email me, we'll talk :)
No signature.

 

Offline IceFire

  • GTVI Section 3
  • 212
    • http://www.3dap.com/hlp/hosted/ce
You just have to deal with the PHP elements that we use.  No worries, if you've got HTML under your belt, this won't be too hard at all.

If I can do it...
- IceFire
BlackWater Ops, Cold Element
"Burn the land, boil the sea, you can't take the sky from me..."

 

Offline Bobboau

  • Just a MODern kinda guy
    Just MODerately cool
    And MODest too
  • 213
why can't the game do all this, I thought it had some sort of IRC code in it
Bobboau, bringing you products that work... in theory
learn to use PCS
creator of the ProXimus Procedural Texture and Effect Generator
My latest build of PCS2, get it while it's hot!
PCS 2.0.3


DEUTERONOMY 22:11
Thou shalt not wear a garment of diverse sorts, [as] of woollen and linen together

 

Offline Inquisitor

It can, I was just doing something quick and simple that we could model from ; )
No signature.

 

Offline EdrickV

  • Valued
  • 29
    • http://members.aol.com/HunterComputers
Quote
Originally posted by Bobboau
why can't the game do all this, I thought it had some sort of IRC code in it


"Had" being the key word. The PXO stuff (or at least the main part of the PXO stuff) was removed before the source was released because it's Parallax's stuff not Volitions.
Ground - "Let me help you out, you're clear to taxi any way you can, to any runway you see."

Mesh Gallery/Downloads:
http://members.aol.com/ArisKalzar/Gallery.html
Turreting 101:
http://members.aol.com/EdrickV/FS2/Turreting.html

http://members.aol.com/HunterComputers

 

Offline Inquisitor

The goal os to put it back in game, I just wanted something quick and dirty ;)

This is my way of prototyping thru the issues. It was also a convenient way for me to relearn mIRC scripting ;)
« Last Edit: November 20, 2002, 07:30:56 am by 122 »
No signature.

 

Offline Bobboau

  • Just a MODern kinda guy
    Just MODerately cool
    And MODest too
  • 213
I thought the IRC code was still in there, only the internal logging in-out stuff was cut, but I havn't looked at the multiplayer code at all so I have no real idea
Bobboau, bringing you products that work... in theory
learn to use PCS
creator of the ProXimus Procedural Texture and Effect Generator
My latest build of PCS2, get it while it's hot!
PCS 2.0.3


DEUTERONOMY 22:11
Thou shalt not wear a garment of diverse sorts, [as] of woollen and linen together

 

Offline EdrickV

  • Valued
  • 29
    • http://members.aol.com/HunterComputers
As far as I can tell, the entire PXO chat interface/game list user interface code was removed. I'm not sure about the code that actually handled the messages for the chat system. I'm pretty sure the briefing chat stuff is still there though, but have no idea where and am not entirely sure it's the same as the PXO chat lobby code. There is also PXO related code scattered throughout the multiplayer files that might be useful if we ever make a PXO like server. (One that keeps track of stats and stuff.)
Ground - "Let me help you out, you're clear to taxi any way you can, to any runway you see."

Mesh Gallery/Downloads:
http://members.aol.com/ArisKalzar/Gallery.html
Turreting 101:
http://members.aol.com/EdrickV/FS2/Turreting.html

http://members.aol.com/HunterComputers

 

Offline Stealth

  • Braiiins...
  • 211
Quote
Originally posted by Inquisitor
You have to respond to the email I sent ;) I  understand you volunteered to help caretake the tester list.

Email me, we'll talk :)


i have?

i will email you :)

Quote

You just have to deal with the PHP elements that we use. No worries, if you've got HTML under your belt, this won't be too hard at all.

If I can do it...


i can get around in PHP, i'm just not very good at it.

if you can do it go ahead... but i thought what with the source code programming, VW, etc. you might be a little too busy ;)

 

Offline Stealth

  • Braiiins...
  • 211
Quote
Originally posted by EdrickV


"Had" being the key word. The PXO stuff (or at least the main part of the PXO stuff) was removed before the source was released because it's Parallax's stuff not Volitions.


isn't Parallax a part of Volition, Inc.?

 

Offline Galemp

  • Actual father of Samus
  • 212
  • Ask me about GORT!
    • Steam
    • User page on the FreeSpace Wiki
Parallax broke into Volition and Outrage, (haven't heard from them since D3, actually...) so PXO is probably jointly owned by them.
"Anyone can do any amount of work, provided it isn't the work he's supposed to be doing at that moment." -- Robert Benchley

Members I've personally met: RedStreblo, Goober5000, Sandwich, Splinter, Su-tehp, Hippo, CP5670, Terran Emperor, Karajorma, Dekker, McCall, Admiral Wolf, mxlm, RedSniper, Stealth, Black Wolf...

 

Offline EdrickV

  • Valued
  • 29
    • http://members.aol.com/HunterComputers
Quote
Originally posted by GalacticEmperor
Parallax broke into Volition and Outrage, (haven't heard from them since D3, actually...) so PXO is probably jointly owned by them.


THQ bought (or otherwise acquired) Outrage. And apparently Outrage is still doing stuff, but for console systems.
Ground - "Let me help you out, you're clear to taxi any way you can, to any runway you see."

Mesh Gallery/Downloads:
http://members.aol.com/ArisKalzar/Gallery.html
Turreting 101:
http://members.aol.com/EdrickV/FS2/Turreting.html

http://members.aol.com/HunterComputers

  

Offline Bobboau

  • Just a MODern kinda guy
    Just MODerately cool
    And MODest too
  • 213
so what progress has been made on this front?
Bobboau, bringing you products that work... in theory
learn to use PCS
creator of the ProXimus Procedural Texture and Effect Generator
My latest build of PCS2, get it while it's hot!
PCS 2.0.3


DEUTERONOMY 22:11
Thou shalt not wear a garment of diverse sorts, [as] of woollen and linen together