Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - !

#16
Well I was not talking about the angle it was about the vehicle rotation( it returns values 100% accurate ) but if you do want to flip the vehicle while its angle is same as before there is a snippet which will provide a little help.

https://forum.vc-mp.org/?topic=5758.msg41727#msg41727


I do know the main aim of the topic is to alert dev to implement the suggestion of allowing player angle to be synced while in vehicle but I would request to remove the temp solution although it is a simple hack to get around but not a better way of doing it like this.
#17
Quote from: Motley on Oct 04, 2018, 12:27 PMI noted
QuoteThat Method oddly doesn't always return the right angle 80% of the time,
returns 100% accurate in all cases.
#18
function getVehicleAngle( veh )
{
  /* Check if vehicle exist */
  if ( !veh ) return;
 
  /* Get the index w of vehicle rotation */
  local quaternionW = Vehicle.Rotation.w;
 
  /* Check if it is not greater than 1 */
  if ( quaternionW > 1 ) quaternionW = 1;
 
  /* apply the formula to get the angle in radians from quaternion */
  local radian = 2 * acos( quaternionW );
 
  /* return the result */
  return radian;
}

/* Some other conversions by an unknown user */
function DegtoRad(  degree ) return degree * 0.0174533;
function RadtoDeg( radian ) return radian * 57.2958;
#19
Object Showroom / Re: Stunt Tubes
Oct 02, 2018, 11:06 AM
Client side creation of objects is better than creating from server side, better use XML
#20
Quote from: GooDNewS on Sep 28, 2018, 05:44 PMWOW a special role! Nice :-)

Nowadays every single retarded teenager creating his own discord "server" to have powership over others somewhere.
WOW used VPN registered with another fake account just to post this.

Nowadays every single retarded teenager creating his fake account "vcmp forum" to have permission over blaming others.
#22
Quote from: =RK=MarineForce on Sep 26, 2018, 12:31 PMhow can i add ? when player type
 if ( cmd == "flagattach" )
{
player attack PickedID = 6000 how can i do this like simple Player.Attach.PickupID = 6005;
}

attach player ID

If you have installed mine version you can attach any of the instance[ player, pickup, vehicle, object ] to any of instance[ player, pickup, vehicle, object ]
means for attaching pickup to bike
local instancePickup = FindPickup( integer pickupID );
local instanceVehicle = FindVehicle( integer vehicleID );

attachEntity( instancePickup, instanceVehicle,Vector( 0, 0, 3 ) );

 :edit: For the original snippet
Usage if I am not wrong
Will not work better use the above one. Clk
local instancePickup = FindPickup( integer pickupID );
local instancePlayer = FindPlayer( integer playerID );

instancePlayer.Attach( "CPickup", instancePickup, Vector( 0, 0, 3 ) );
#23
Quote from: doxuanhien2002 on Sep 25, 2018, 01:34 PMCan someone give me the ban system by zeus
A few months ago, I saw it in the extracted library
now i can not find the ban system
Why do you need a buggy ban system?
#24
Well you can not do it in just one line unless a function is created which handles the relative positions and sizes of all GUI in it.Calling this function will re-position all GUIs.

 :edit: PM for a help over discord.
#25
Support / Re: Property system bug
Sep 16, 2018, 07:17 PM
Quote from: Nihongo^ on Sep 16, 2018, 04:30 PMHi thanka for your kind reply
I am sorry I am noon in scripting just started recently
 I replace it with numtok kindly check the code o think I did it wrong can u correct it if you don't mind

else if( typeof( IsNum( text, " ", 1 ).tointeger() ) != "integer" ) return pMSG( "Error - Usually 'price' means numbers...", player );

Correct
else if( !IsNum( GetTok( text, " ", 1 ) ) ) return pMSG( "Error - Usually 'price' means numbers...", player );
#26
Support / Re: Property system bug
Sep 16, 2018, 02:05 PM
Use IsNum( arg )
if ( !IsNum( text ) ) return print( "Error >> Expected an integer." );


typeof
It returns the name of type to which the passed argument belongs.
#27
General Discussion / Re: [Suggestion] Memobox
Sep 16, 2018, 10:43 AM
Quote from: XForce111 on Sep 16, 2018, 10:28 AMPost your suggestion in my policy topic here: https://forum.vc-mp.org/?topic=5626.0
It is not necessary for everyone to post suggestion in specific topic unless a special board for such topic is created we do want to increase our posted topics count :)
#28
Quote from: =RK=MarineForce on Sep 15, 2018, 08:58 PMAn updated plugin pack for 04rel006 servers can be found here:
https://v04.vc-mp.org/all...plugins_04rel006_patch2.7z

I added this . but its showing me 0.4 version .
Download server executable from this link and put it in svr_dir
Clicky
#29
Use AUTO INCREMENT rather using custom made functions.

QuoteAuto-increment allows a unique number to be generated automatically when a new record is inserted into a table.

Often this is the primary key field that we would like to be created automatically every time a new record is inserted.

Detailed Information & usage
Clicky
#30
Quote from: MEGAMIND on Sep 11, 2018, 09:18 AMis there a method to do it like this?

function SendDataToClient( player, integer, string )
{
 if ( FindPlayer( player ) )
 {

 Stream.StartWrite( );
 Stream.WriteInt( integer );
 if ( string != null ) Stream.WriteString( string );
 Stream.SendStream( FindPlayer( player ) );
  //Stream.SendStream(player);
 
 }
 else
 {
 Stream.StartWrite( );
 Stream.WriteInt( integer );
 if ( string != null ) Stream.WriteString( string );
 Stream.SendStream(player);
 }

}


}
or can we use switch case if yes then how
Yes there is

function SendDataToClient( player, integer, string )
{
  if ( typeof( player )  != "Instance" ) player = FindPlayer( player );
  if ( !player ) return;
 
  Stream.StartWrite( );
  Stream.WriteInt( integer );
  if ( string != null ) Stream.WriteString( string );
  Stream.SendStream( player );
}