![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Feb 2005
Posts: 2
Rep Power: 0
![]() |
best method of starting another program?
Hi, im new here and I have a question.
I'm trying to make a gui in vb6 that will pass parameters to an external program. I've read that you can do that it can be done with Shell(), ShellExecute() or ShellExecuteEx() but I don't know which way would be best to do this. Maybe there's a better way than those? The programs (there's 3) that I am trying to send these parameters to are called vbsp.exe, vvis.exe, and vrad.exe. If anyone plays hl2 and maps for it you'd recognize these programs. What they do is build the level and compile it into a .bsp file that you play the game with. Anyway, the way you run these programs is like this: (I'll use vbsp.exe for the example) vbsp [options...] mapfile Where [options] are the parameters and mapfile is a .vmf file. Which way is would be best to run the program and give it the parameters a user would select? Thanks for anyhelp. |
|
|
|
|
|
#2 |
|
I eat cake for breakfast.
![]() ![]() ![]() ![]() Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9
![]() |
IIRC, Shell will do you fine. If it doesn't, try ShellExecute.
|
|
|
|
|
|
#3 |
|
Newbie
Join Date: Feb 2005
Posts: 2
Rep Power: 0
![]() |
Ok I will try that.
Thank you |
|
|
|
|
|
#4 |
|
Expert Programmer
|
To the best of my knowledge the mesh files need to be passed through StdIn rather than as command line parameters - that's what the console thing on the Valve Hammer editor (haven't used it for ages!) does - if not your BSP file may not be fully optimised and may get artefacts (holes, low-res lighting etc).
You can do this from cmd (just use the ">" directive) and in VB the simplest way is to use the FileSystemObject, though there are API alternatives. |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|