Quantcast

Jump to content

» «
Photo

GTA IV MP Server Title

6 replies to this topic
Jimbatron
  • Jimbatron

    Big Homie

  • Members
  • Joined: 08 Jan 2009
  • United-Kingdom
  • Most Helpful GTA Topic 2017 [The Lone Wolf's Guide to Making Money and Research]

#1

Posted 31 December 2016 - 11:44 AM Edited by Jimbatron, 31 December 2016 - 11:46 AM.

A quick question. Is there a native function, or simple set of code, to set the server title in a GTA IV multiplayer match - that can be normally typed in?

 

I think the native function NETWORK_SET_SERVER_NAME may do this but not sure.

 

If you wonder why I'm asking, I have already created a modded multiplayer mode for IV (no cheating, it's just a new map, see here - http://gtaforums.com...0-for-the-pc/).I don't want to publicly distribute it however unless I can insert some code that overwrites the title so people can see the mod is being used (much like sjaak's simple native trainer does if you host a freemode lobby).


3ncode_gaming
  • 3ncode_gaming

    Dilemma Maker

  • Members
  • Joined: 31 Dec 2016
  • United-States

#2

Posted 31 December 2016 - 11:01 PM

i would recommend you try to find some archives of the IVMP to help you with the code on their website it has archives but some broken if anything you could email sjaak here's his email [email protected]

  • Jimbatron likes this

Jimbatron
  • Jimbatron

    Big Homie

  • Members
  • Joined: 08 Jan 2009
  • United-Kingdom
  • Most Helpful GTA Topic 2017 [The Lone Wolf's Guide to Making Money and Research]

#3

Posted 01 January 2017 - 10:44 AM

Thanks I have messaged sjaak, heard back once but I think he might be busy

ClareXoBearrx3R9
  • ClareXoBearrx3R9

    'su' isn't the f*cking same as 'sudo'.

  • Members
  • Joined: 13 Aug 2010
  • United-States

#4

Posted 02 January 2017 - 04:33 AM

A quick question. Is there a native function, or simple set of code, to set the server title in a GTA IV multiplayer match - that can be normally typed in?

 

I think the native function NETWORK_SET_SERVER_NAME may do this but not sure.

 

If you wonder why I'm asking, I have already created a modded multiplayer mode for IV (no cheating, it's just a new map, see here - http://gtaforums.com...0-for-the-pc/).I don't want to publicly distribute it however unless I can insert some code that overwrites the title so people can see the mod is being used (much like sjaak's simple native trainer does if you host a freemode lobby).

 

You are correct; the NETWORK_SET_SERVER_NAME native does just that. ;)

  • Jimbatron likes this

Jimbatron
  • Jimbatron

    Big Homie

  • Members
  • Joined: 08 Jan 2009
  • United-Kingdom
  • Most Helpful GTA Topic 2017 [The Lone Wolf's Guide to Making Money and Research]

#5

Posted 02 January 2017 - 10:32 AM Edited by Jimbatron, 02 January 2017 - 10:34 AM.

 

A quick question. Is there a native function, or simple set of code, to set the server title in a GTA IV multiplayer match - that can be normally typed in?

 

I think the native function NETWORK_SET_SERVER_NAME may do this but not sure.

 

If you wonder why I'm asking, I have already created a modded multiplayer mode for IV (no cheating, it's just a new map, see here - http://gtaforums.com...0-for-the-pc/).I don't want to publicly distribute it however unless I can insert some code that overwrites the title so people can see the mod is being used (much like sjaak's simple native trainer does if you host a freemode lobby).

 

You are correct; the NETWORK_SET_SERVER_NAME native does just that. ;)

 

 

Many thanks Clare. I can probably test modding freemode to get it to work, but I don't suppose if you know what the inputs are to this function? E.g is it as simple as NETWORK_SET_SERVER_NAME ("Title of my choice")                ?

 

Apologies I'm still relatively new to SCO coding. I've worked out bits and pieces as I've gone along rather than having a good overview of it all.

  • ClareXoBearrx3R9 likes this

ClareXoBearrx3R9
  • ClareXoBearrx3R9

    'su' isn't the f*cking same as 'sudo'.

  • Members
  • Joined: 13 Aug 2010
  • United-States

#6

Posted 02 January 2017 - 10:39 PM

 

 

A quick question. Is there a native function, or simple set of code, to set the server title in a GTA IV multiplayer match - that can be normally typed in?

 

I think the native function NETWORK_SET_SERVER_NAME may do this but not sure.

 

If you wonder why I'm asking, I have already created a modded multiplayer mode for IV (no cheating, it's just a new map, see here - http://gtaforums.com...0-for-the-pc/).I don't want to publicly distribute it however unless I can insert some code that overwrites the title so people can see the mod is being used (much like sjaak's simple native trainer does if you host a freemode lobby).

 

You are correct; the NETWORK_SET_SERVER_NAME native does just that. ;)

 

 

Many thanks Clare. I can probably test modding freemode to get it to work, but I don't suppose if you know what the inputs are to this function? E.g is it as simple as NETWORK_SET_SERVER_NAME ("Title of my choice")                ?

 

Apologies I'm still relatively new to SCO coding. I've worked out bits and pieces as I've gone along rather than having a good overview of it all.

 

 

No problem :)

 

I believe that native function takes just one argument, the name you wish to set. Now I am not familiar with SCO coding, but in C++, something along the lines of the following should suffice:

void set_server_name(std::string name){

	std::stringstream ss;
	ss << name;
	NETWORK_SET_SERVER_NAME(ss.str().c_str());
}

or even something like this:

void set_server_name(std::string name){

	char namebuff[32];
	sprintf_s(namebuff, "%s", name.c_str());
	NETWORK_SET_SERVER_NAME(namebuff);
}

Hope that helps :)

  • Jimbatron likes this

Jimbatron
  • Jimbatron

    Big Homie

  • Members
  • Joined: 08 Jan 2009
  • United-Kingdom
  • Most Helpful GTA Topic 2017 [The Lone Wolf's Guide to Making Money and Research]

#7

Posted 02 January 2017 - 10:54 PM Edited by Jimbatron, 02 January 2017 - 10:55 PM.

Hope that helps :)

 

 

Thanks again I think it will!

  • ClareXoBearrx3R9 likes this




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users