With cordite in the air, splintered steel, shell casings and powder burns, there’s only one explanation...
Post feedback & meet new friends. General SG discussion.

Moderators: Pardner, TheDoctor

More than a little help here please

Postby [PTR]Manoel Victor » Tue Jul 26, 2011 12:03 am

Hello again everyone!
Well, I want to do something ...
Like I saw in a server, I set on my server, it kind of being special, at each stage has only one weapon that can be used, for example, is the phase dm_canyon sharps rifle, and then when someone tries to buy the other item will appear written:
"It's just you and your Sharps, can not buy anything"
The only thing that will be able to buy ammunition or the ammunition belt.
And type in each phase I set a weapon, and it eventually times out, etc., so that the ends dm_canyon for example, goes to San blade, can only use Colt lightning, you know? And so it goes, I'm going to do and by setting the weapons they can use them, oh, and I saw the server, map of Durango, who I know BR is only for the DM guys playing it!
How??
I also want to do it!
Thanks in advance and I await answers!
User avatar
[PTR]Manoel Victor
Quick Draw
 
Posts: 71
Joined: Fri Apr 01, 2011 11:04 pm
Location: Brasil



Re: More than a little help here please

Postby TheDoctor » Sun Aug 14, 2011 9:45 pm

Manoel Victor wrote:I want to clone (parts of) Special Bude (SB).

Disclaimer: SB is a non-standard mod and thus requires changes to the SG source code. If you don't know how to patch/modify the source code and how to compile Smokin' Guns, you won't be able to (fully) duplicate SB's functionality.


That said, the presence of function G_ItemDisabled(gitem_t *) in game/g_items.c suggests, you can deactivate (reactivate) certain weapons by executing
Code: Select all
\seta disable_WP_WEAPON 1
\seta disable_WP_WEAPON 0
in the server console or via RCON, whereby WEAPON is of the following designators: WP_KNIFE, WP_REM58, WP_SCHOFIELD, WP_PEACEMAKER, and so forth.

Code: Select all
/*
============
G_ItemDisabled
============
*/
int G_ItemDisabled( gitem_t *item ) {

   char name[128];

   Com_sprintf(name, sizeof(name), "disable_%s", item->classname);
   return trap_Cvar_VariableIntegerValue( name );
}


/*
 the following items may apply to G_ItemDisabled:
   WP_KNIFE,

   //pistols
   WP_REM58,
   WP_SCHOFIELD,
   WP_PEACEMAKER,

   //rifles
   WP_WINCHESTER66,   // should always be the first weapon after pistols
   WP_LIGHTNING,
   WP_SHARPS,

   //shotguns
   WP_REMINGTON_GAUGE,
   WP_SAWEDOFF,
   WP_WINCH97,

   //automatics
   WP_GATLING,

   //explosives
   WP_DYNAMITE,   // this always should be the last weapon after the special weapons
   WP_MOLOTOV,      // has to be the last weapon in here, because of the +prevweap-cmd

   WP_NUM_WEAPONS,

   WP_AKIMBO,

   WP_BULLETS_CLIP,
   WP_SHELLS_CLIP,
   WP_CART_CLIP,
   WP_GATLING_CLIP,
   WP_SHARPS_CLIP, // 21 !! no more place in weapons-storage !

   // For representing the left side pistol when the player has two of the
   // same kind.  This is NOT a valid index for playerState_t.ammo.
   WP_SEC_PISTOL
*/

You could include these calls in your map selection cycle. Since this code exists in SVN 1.0 branch, I assume it works in the SG1.0 release (but I'm to lazy to try it out for you).


Aside from this, for a more flexible weapon selection, there's this post for a starter. If it doesn't help you, please accept, you won't be able to effortless duplicate SB.
User avatar
TheDoctor
Smokin' Amigo!
 
Posts: 818
Joined: Sun Jun 06, 2010 3:31 am



Re: More than a little help here please

Postby [PTR]Manoel Victor » Mon Aug 15, 2011 4:03 am

I did not find this file, my version of SG is 1.0, and also, I downloaded an editor PK3 but every time I open, for example, the file teamplay bot to translate into Portuguese, when I click save, it saves, but if I open again, there is still the same, cutting my translation and the pattern continues, in English, it does not save!
Please help me out there, ask for help to my good friend Pardner, who always helped me! Please help me Pardner, now thanks.
User avatar
[PTR]Manoel Victor
Quick Draw
 
Posts: 71
Joined: Fri Apr 01, 2011 11:04 pm
Location: Brasil



Re: More than a little help here please

Postby Pardner » Mon Aug 15, 2011 5:01 pm

Manoel Victor wrote:I did not find this file

The source code is not included in the game download. It must be downloaded separately from here:
http://sourceforge.net/projects/smokinguns/files/


Manoel Victor wrote:I downloaded an editor PK3 but every time I open, for example, the file teamplay bot to translate into Portuguese, when I click save, it saves, but if I open again, there is still the same, cutting my translation and the pattern continues, in English, it does not save!



DO NOT MODIFY ANY FILES IN THE INCLUDED PK3

If you want to modify files, you will need to copy them out of the pk3, modify them, and then zip them up into a new pk3. So if you want to make new bot files, you will need to copy the following out of sg_pak0.pk3:
  • botfiles/bots/male1_c.c
  • botfiles/bots/male1_i.c
  • botfiles/bots/male1_t.c
  • botfiles/bots/male1_w.c

Then rename them to something like:
  • botfiles/bots/male1_portuguese_c.c
  • botfiles/bots/male1_portuguese_i.c
  • botfiles/bots/male1_portuguese_t.c
  • botfiles/bots/male1_portuguese_w.c

Then have your bot use the male1_portuguese bot file:
Code: Select all
{
name       Pardner
funname    "^3Pardner"
model      wq_male2/red
aifile     bots/male1_portuguese_c.c
}
User avatar
Pardner
SG Team
 
Posts: 1786
Joined: Fri Nov 18, 2005 5:48 am
Location: MD, USA



Re: More than a little help here please

Postby [PTR]Manoel Victor » Tue Aug 16, 2011 5:02 pm

Pardner wrote:
Manoel Victor wrote:I did not find this file

The source code is not included in the game download. It must be downloaded separately from here:
http://sourceforge.net/projects/smokinguns/files/


Manoel Victor wrote:I downloaded an editor PK3 but every time I open, for example, the file teamplay bot to translate into Portuguese, when I click save, it saves, but if I open again, there is still the same, cutting my translation and the pattern continues, in English, it does not save!



DO NOT MODIFY ANY FILES IN THE INCLUDED PK3

If you want to modify files, you will need to copy them out of the pk3, modify them, and then zip them up into a new pk3. So if you want to make new bot files, you will need to copy the following out of sg_pak0.pk3:
  • botfiles/bots/male1_c.c
  • botfiles/bots/male1_i.c
  • botfiles/bots/male1_t.c
  • botfiles/bots/male1_w.c

Then rename them to something like:
  • botfiles/bots/male1_portuguese_c.c
  • botfiles/bots/male1_portuguese_i.c
  • botfiles/bots/male1_portuguese_t.c
  • botfiles/bots/male1_portuguese_w.c

Then have your bot use the male1_portuguese bot file:
Code: Select all
{
name       Pardner
funname    "^3Pardner"
model      wq_male2/red
aifile     bots/male1_portuguese_c.c
}

Pardner, I downloaded the 3 files that are version 1.0, came a few files, a folder called "stable", another folder called "win32-replacement" and a file with extension. Tar, called "sg-1.0-svn_r48.tar "but I do not know what to do with these files! Please ask you to pass me a tutorial like the one of the bots, which helped me a lot!
Oh, and I will take the opportunity to ask for help in something else too, as I change the port my server? Because I want to make a common server and the other with these changes, but must be on the same computer!
I await your help friend!
User avatar
[PTR]Manoel Victor
Quick Draw
 
Posts: 71
Joined: Fri Apr 01, 2011 11:04 pm
Location: Brasil



Re: More than a little help here please

Postby Pardner » Tue Aug 16, 2011 5:20 pm

Manoel Victor wrote:Pardner, I downloaded the 3 files that are version 1.0, came a few files, a folder called "stable", another folder called "win32-replacement" and a file with extension. Tar, called "sg-1.0-svn_r48.tar "but I do not know what to do with these files! Please ask you to pass me a tutorial like the one of the bots, which helped me a lot!

you want the one called /sg-1.0-svn_r48.zip and here is a tutorial:
viewtopic.php?t=1842

Manoel Victor wrote:Oh, and I will take the opportunity to ask for help in something else too, as I change the port my server? Because I want to make a common server and the other with these changes, but must be on the same computer!
I await your help friend!

in the server config set net_port 27960
User avatar
Pardner
SG Team
 
Posts: 1786
Joined: Fri Nov 18, 2005 5:48 am
Location: MD, USA



Re: More than a little help here please

Postby [PTR]Manoel Victor » Tue Aug 16, 2011 6:01 pm

Manoel Victor wrote:
Pardner, I downloaded the 3 files that are version 1.0, came a few files, a folder called "stable", another folder called "win32-replacement" and a file with extension. Tar, called "sg-1.0-svn_r48.tar "but I do not know what to do with these files! Please ask you to pass me a tutorial like the one of the bots, which helped me a lot!

you want the one called /sg-1.0-svn_r48.zip and here is a tutorial:
viewtopic.php?t=1842

Manoel Victor wrote:
Oh, and I will take the opportunity to ask for help in something else too, as I change the port my server? Because I want to make a common server and the other with these changes, but must be on the same computer!
I await your help friend!

in the server config set net_port 27960

Pardner, but in my server setup does not have that option!
And I could not understand that tutorial, and I can not even download the Visual Studio!
And I do not know what to do with the files I downloaded, you had given me, I can spend a tutorial please?
User avatar
[PTR]Manoel Victor
Quick Draw
 
Posts: 71
Joined: Fri Apr 01, 2011 11:04 pm
Location: Brasil



Re: More than a little help here please

Postby Pardner » Tue Aug 16, 2011 7:22 pm

Manoel Victor wrote:Pardner, but in my server setup does not have that option!

Add it then.

Manoel Victor wrote:And I could not understand that tutorial, and I can not even download the Visual Studio!And I do not know what to do with the files I downloaded, you had given me, I can spend a tutorial please?

You don't download Visual Studio, you buy it or use your school's. If you have never done coding before, the it is going to be very tough. I looked and I guess the build scripts are not included in those zip files. You will need to follow that tutorial that I posted earlier and use TortoiseSVN to download the code. Also I noticed that there isn't any Windows build scripts for the 1.0 release (we will cross that bridge when we come to it). For now, you will need to "checkout" the following address:
https://smokinguns.svn.sourceforge.net/svnroot/smokinguns/trunk
here is the tutorial step:
Sucalakafufu wrote:FINALLY WE NEED THE SOURCE CODE ITSELF.
Use a subversion client like Tortoise SVN to keep updated with the latest revisions of SG 1.1 & 1.0 (if you have a 64 bit comp you need TortoiseSVN 64 bit)
To get the source code using TortoiseSVN first install Tortoise. After it is installed, create a folder wherever you want the SG code to be. Name it anything you want. Then right click on this folder and click SVN Checkout.
Image

Then copy this URL: https://smokinguns.svn.sourceforge.net/ ... uns/trunk/ into the "URL of repository" box.
Image


So, why don't you try getting TortSVN running, use it to download the code, then post back here so we can move onto the next step.
User avatar
Pardner
SG Team
 
Posts: 1786
Joined: Fri Nov 18, 2005 5:48 am
Location: MD, USA



Re: More than a little help here please

Postby [PTR]Manoel Victor » Tue Aug 16, 2011 7:32 pm

Pardner wrote:
Manoel Victor wrote:Pardner, but in my server setup does not have that option!

Add it then.

Manoel Victor wrote:And I could not understand that tutorial, and I can not even download the Visual Studio!And I do not know what to do with the files I downloaded, you had given me, I can spend a tutorial please?

You don't download Visual Studio, you buy it or use your school's. If you have never done coding before, the it is going to be very tough. I looked and I guess the build scripts are not included in those zip files. You will need to follow that tutorial that I posted earlier and use TortoiseSVN to download the code. Also I noticed that there isn't any Windows build scripts for the 1.0 release (we will cross that bridge when we come to it). For now, you will need to "checkout" the following address:
https://smokinguns.svn.sourceforge.net/svnroot/smokinguns/trunk
here is the tutorial step:
Sucalakafufu wrote:FINALLY WE NEED THE SOURCE CODE ITSELF.
Use a subversion client like Tortoise SVN to keep updated with the latest revisions of SG 1.1 & 1.0 (if you have a 64 bit comp you need TortoiseSVN 64 bit)
To get the source code using TortoiseSVN first install Tortoise. After it is installed, create a folder wherever you want the SG code to be. Name it anything you want. Then right click on this folder and click SVN Checkout.
Image

Then copy this URL: https://smokinguns.svn.sourceforge.net/ ... uns/trunk/ into the "URL of repository" box.
Image


So, why don't you try getting TortSVN running, use it to download the code, then post back here so we can move onto the next step.

Pardner, I tried to add the list, but to no avail, the door remains the 27960.
And I still do not understand the tutorial, maybe it's because I'm not familiar with English lol.
And now I'll say it since the Visual Studio I can not get anywhere! I need him to do something? Because to be honest, I did not understand anything yet!
Also, I did so to translate the file:
I downloaded an editor PK3, sg_pak0.pk3 open the files and there were, I drew them, translate, then put him back in PK3 format, but then when I added the bot, appeared "BotSetupClient faliled, Could not load bots/male1_t.c chat "about stuff you know?
How do I do?
Please Pardner, I'm counting on you to learn to move the files, and configure my server to my taste, leaving Durango as the DM envés BR, selecting weapons for each particular stage, etc.!
Please, I want to learn, but for that I need your help!
User avatar
[PTR]Manoel Victor
Quick Draw
 
Posts: 71
Joined: Fri Apr 01, 2011 11:04 pm
Location: Brasil



Postby Pardner » Tue Aug 16, 2011 11:54 pm

  1. Download and install TortoiseSVN client: 32bit or 64bit
  2. Create a new folder where you want to save your source code.
  3. Right click on the newly created folder and select "Checkout"
    Image
  4. In the window that opens, enter the following address in the "URL of repository" field
    https://smokinguns.svn.sourceforge.net/svnroot/smokinguns/trunk
    then click "OK"
    Image

Post back when you get that far.
Manoel Victor wrote:Pardner, I tried to add the list, but to no avail, the door remains the 27960.

Try adding to the shortcut target, so you shortcut target should be something like:
Code: Select all
*smokinguns.exe +set net_port 27960 +exec server.cfg


Manoel Victor wrote:And now I'll say it since the Visual Studio I can not get anywhere! I need him to do something? Because to be honest, I did not understand anything yet!

Visual Studio is nice because you can load the vcpoject file and quickly search all the files at once. You can do Doctor's mod in notepad.

Manoel Victor wrote:Could not load bots/male1_t.c chat "

Your bot is still pointing to the old file, it should be pointing to the new file (which should not be named the same as the old file)

Manoel Victor wrote:Please Pardner, I'm counting on you to learn to move the files, and configure my server to my taste, leaving Durango as the DM envés BR, selecting weapons for each particular stage, etc.!

I hope at some point things start to make sense for you. I really have not done do much with the code and running mods. I prefer the mapping side of things.
User avatar
Pardner
SG Team
 
Posts: 1786
Joined: Fri Nov 18, 2005 5:48 am
Location: MD, USA



Postby [PTR]Manoel Victor » Wed Aug 17, 2011 12:25 am

Gosh, Americans do not really let me down! That's why I love this country! I love the USA!
How I wish I was born there, sorry if it escapes the subject, but I really love the story! Uncle Sam, the Old West, the most spoken language in the world, the most developed country, everything comes from you! I tip my hat to the U.S., because I really love this country, I would even buy a colt 45, but guess why I said "would", because here in Brazil they do not, a great drug, I had saved the money was a réplcia Colt 45 Peacemaker, but the customs here, do not want to leave. Well, do what, the fact is that I hope one day to travel up there and realize my dream of visiting Texas, and American's 4-4-0 (trains of the old west) that are preserved in the museum the 4-4-0 "Generals" of Texas.
Well Pardner, sorry for the change of subject, but since I can talk to an American, "let go".
Now back to the subject:
*smokinguns.exe +set net_port 27960 +exec server.cfg

This change will disrupt something, for example, my server is not listed?
Oh, and I'm downloading the SVN now, and I will follow the steps you gave me when I finish, you tell me what I should do next.
10 minutes after this post ...
All done gunman, what next?
Do not connect, Brazilians like to play. :roll:
User avatar
[PTR]Manoel Victor
Quick Draw
 
Posts: 71
Joined: Fri Apr 01, 2011 11:04 pm
Location: Brasil



Postby Pardner » Wed Aug 17, 2011 12:59 am

Manoel Victor wrote:All done gunman, what next?

  1. As I mentioned before, the 1.0 trunk does not have the qvm build scripts. So..
  2. Right-click on the folder where you have the source saved. Then select TortoiseSVN --> Repo-Browser
  3. In the Repo-Browser, navigate to the following location: https://smokinguns.svn.sourceforge.net/svnroot/smokinguns/branches/1.1/
  4. Right-click on the misc folder and select "export", "save-as" , or even click&drag the folder into your source code folder. You should have the folling folders in your source folder:
    Image
  5. I have not tested this part, in misc/win32, double click the cleanvm.cmd and then the buildvm.cmd
  6. You should see a new folder in your source folder called "build"
  7. right click on the folder named vm and select Send To --> Compressed folder
  8. renamed new vm.zip to zzz_vm.pk3
  9. place in your smokinguns folder

I am not in front of my windows machine, and I have not tried building the 1.0 qvm with the 1.1 build script. I hope it works.

[/list]
User avatar
Pardner
SG Team
 
Posts: 1786
Joined: Fri Nov 18, 2005 5:48 am
Location: MD, USA



Postby [PTR]Manoel Victor » Wed Aug 17, 2011 1:29 am

Pardner wrote:
Manoel Victor wrote:All done gunman, what next?

  1. As I mentioned before, the 1.0 trunk does not have the qvm build scripts. So..
  2. Right-click on the folder where you have the source saved. Then select TortoiseSVN --> Repo-Browser
  3. In the Repo-Browser, navigate to the following location: https://smokinguns.svn.sourceforge.net/svnroot/smokinguns/branches/1.1/
  4. Right-click on the misc folder and select "export", "save-as" , or even click&drag the folder into your source code folder. You should have the folling folders in your source folder:
    Image
  5. I have not tested this part, in misc/win32, double click the cleanvm.cmd and then the buildvm.cmd
  6. You should see a new folder in your source folder called "build"
  7. right click on the folder named vm and select Send To --> Compressed folder
  8. renamed new vm.zip to zzz_vm.pk3
  9. place in your smokinguns folder

I am not in front of my windows machine, and I have not tried building the 1.0 qvm with the 1.1 build script. I hope it works.

[/list]

Okay, I've put it, but it has a detail, it is empty, oh and the right directory is Smokin Guns 1.0> smokinguns is not it?
And Pardner,please change my name to [PTR]Manoel Victor
Thanks.
User avatar
[PTR]Manoel Victor
Quick Draw
 
Posts: 71
Joined: Fri Apr 01, 2011 11:04 pm
Location: Brasil



Postby [PTR]Manoel Victor » Wed Aug 17, 2011 10:57 pm

I move this topic to SG Forums>SVN
User avatar
[PTR]Manoel Victor
Quick Draw
 
Posts: 71
Joined: Fri Apr 01, 2011 11:04 pm
Location: Brasil



Postby Pardner » Thu Aug 18, 2011 12:40 am

Manoel Victor wrote:I move this topic to SG Forums>SVN

You only need one thread per topic, please don't create multiple threads for the same question. Having multiple threads will not increase the number of responses.

-----------------------------------------------------------

So I tried things out on my windows machine, and I made a mistake. The build scripts are included in the 1.0 code. So your steps should be:
  1. Download and install TortoiseSVN
  2. Checkout https://smokinguns.svn.sourceforge.net/svnroot/smokinguns/trunk/
  3. Double click on the cleanvm.bat
  4. Double click on the buildvm.bat
  5. Navigate to */build
  6. Right-click on the VM folder, and select Send to --> Compressed zip
  7. Rename vm.zip to zz_vm.pk3
  8. Move zz_vm.pk3 to your smokinguns folder
User avatar
Pardner
SG Team
 
Posts: 1786
Joined: Fri Nov 18, 2005 5:48 am
Location: MD, USA



Next

Return to Saloon

Show Sidebar
Show Sidebar

User Control Panel

cron