/OnePunch

Status
Not open for further replies.

ra1z0

Active member
Joined
Mar 24, 2016
Messages
31
Reaction score
0
Code:
* Name of the mod (if the mod doesn't exist, you don't have to tell one): don't exist
 * Where you saw it (not the server, we mean if you saw any videos/screenshots about it or not): i came with idea
 * What do you want (the most important part, explain this carefully) i want when i go near a car and hit it with the punch or animation from the punch to go flying but not that fast  like  i have a really strong punch
 * Details (add more details to your request)
 * On/off key (specify it): /onepunch and then when i press left clic to do it for the nearest car
 

4changesLeft

Well-known member
Joined
Apr 10, 2015
Messages
365
Reaction score
4
That would only work with car control, and onfoot it's kinda ... eh xd
 

0x32789

Expert
Joined
May 26, 2014
Messages
849
Reaction score
51
Location
LongForgotten <-> 0x32789
TehArgis, u dont know alot about packets but let me explain..
ITS POSSIBLE!
How?
First of all, There are some "dis-advantages"..
They are:
The vehicle msut be occupied.
You wont see the vehicle moving in your screen unless someone touches it, But in others screen it is like doing like we wanted (Remember TehArgis when I showed u my unoccupied vehicle data slapper? It was working fine except some mis-fortune which came with the fMoveSpeed.. So I gave up)

How to do it:
Unoccupied Vehicle Data
Code:
stUnOccupiedVehicleData:
struct stUnoccupiedData
{
	int16_t sVehicleID;
	uint8_t byteSeatID;
	float	fRoll[3];
	float	fDirection[3];
	float	fPosition[3];
	float	fMoveSpeed[3];
	float	fTurnSpeed[3];
	float	fHealth;
};

Functions: 
void ForceSendUnoccupiedSync(uint16_t vehicleId, uint8_t seatId); // IDK what this really does but I havent checked the function
(ONLY ON SFAPI, TAKEN FROM 0.3.7 SFAPI C++)
Enjoy.. Make it yourself maybe (I know this is request thread but this is dead asf)
 

ra1z0

Active member
Joined
Mar 24, 2016
Messages
31
Reaction score
0
damn i have no idea how to make it a .cs file ... can u help me ? it's perfect .....
 

Spix

Well-known member
Joined
Sep 23, 2013
Messages
353
Reaction score
1
0x32789 said:
TehArgis, u dont know alot about packets but let me explain..
ITS POSSIBLE!
How?
First of all, There are some "dis-advantages"..
They are:
The vehicle msut be occupied.
You wont see the vehicle moving in your screen unless someone touches it, But in others screen it is like doing like we wanted (Remember TehArgis when I showed u my unoccupied vehicle data slapper? It was working fine except some mis-fortune which came with the fMoveSpeed.. So I gave up)

How to do it:
Unoccupied Vehicle Data
Code:
stUnOccupiedVehicleData:
struct stUnoccupiedData
{
	int16_t sVehicleID;
	uint8_t byteSeatID;
	float	fRoll[3];
	float	fDirection[3];
	float	fPosition[3];
	float	fMoveSpeed[3];
	float	fTurnSpeed[3];
	float	fHealth;
};

Functions: 
void ForceSendUnoccupiedSync(uint16_t vehicleId, uint8_t seatId); // IDK what this really does but I havent checked the function
(ONLY ON SFAPI, TAKEN FROM 0.3.7 SFAPI C++)
Enjoy.. Make it yourself maybe (I know this is request thread but this is dead asf)

So why not making it synced for the client also?

Adding non synced velocity or something to the car also. For others car flies away, for you car flies away :)

And he can see it himself, it just feels better to see it with your own eyes :)
 

0x32789

Expert
Joined
May 26, 2014
Messages
849
Reaction score
51
Location
LongForgotten <-> 0x32789
SpexxTr0n said:
0x32789 said:
TehArgis, u dont know alot about packets but let me explain..
ITS POSSIBLE!
How?
First of all, There are some "dis-advantages"..
They are:
The vehicle msut be occupied.
You wont see the vehicle moving in your screen unless someone touches it, But in others screen it is like doing like we wanted (Remember TehArgis when I showed u my unoccupied vehicle data slapper? It was working fine except some mis-fortune which came with the fMoveSpeed.. So I gave up)

How to do it:
Unoccupied Vehicle Data
Code:
stUnOccupiedVehicleData:
struct stUnoccupiedData
{
	int16_t sVehicleID;
	uint8_t byteSeatID;
	float	fRoll[3];
	float	fDirection[3];
	float	fPosition[3];
	float	fMoveSpeed[3];
	float	fTurnSpeed[3];
	float	fHealth;
};

Functions: 
void ForceSendUnoccupiedSync(uint16_t vehicleId, uint8_t seatId); // IDK what this really does but I havent checked the function
(ONLY ON SFAPI, TAKEN FROM 0.3.7 SFAPI C++)
Enjoy.. Make it yourself maybe (I know this is request thread but this is dead asf)

So why not making it synced for the client also?

Adding non synced velocity or something to the car also. For others car flies away, for you car flies away :)

And he can see it himself, it just feels better to see it with your own eyes :)

lol thanks for reminding
Can some1 come in ugbase.eu server so I can test


IDK that how does it go, But I made it it should work fine.
It works try it urself but I stll dont believe that what we see[attachment=4486][attachment=4486] is same to the other players screen
 

Attachments

  • [%]OnePunch[%].cs
    20.6 KB · Views: 66

0x32789

Expert
Joined
May 26, 2014
Messages
849
Reaction score
51
Location
LongForgotten <-> 0x32789
Better version here, The old one got some probs
BTW..
Hax0r TIP: Use it when dozens of players are around and many or 1 unoccupied vehicle
PRO and STRONG MINDED TIP: Make some players get on the car or on a RP server players might be on a sadler or pickup truck at its trunk, use the cleo and fuck them all in the air lol  :LOL:
:s
[attachment=4487]
 

Attachments

  • [%]OnePunch[%].cs
    20.6 KB · Views: 133

ra1z0

Active member
Joined
Mar 24, 2016
Messages
31
Reaction score
0
can u make the car not spinning that fast and make it throw the car a little futher ? I would so love u
 

0x32789

Expert
Joined
May 26, 2014
Messages
849
Reaction score
51
Location
LongForgotten <-> 0x32789
just change
Code:
07D5: set_car 25@ velocity_in_direction_XYZ -150.0 150.0 75.0 rotation_velocitiesXY 30.0 30.0 unk 0.0
                                                                            to
07D5: set_car 25@ velocity_in_direction_XYZ 60.0 60.0 3.0 rotation_velocitiesXY 0.0 0.0 unk 0.0

and
Code:
alloc 10@ 67                 
0C0D: 10@ 0 2 = 12@              // Vehicle ID
0C0D: 10@ 2 1 = 1               // Seat ID         
0C0D: 10@ 3 4 = 30.0             // fRoll[0]         
0C0D: 10@ 7 4 = 30.0            // fRoll[1]             
0C0D: 10@ 11 4 = 0.0          // fRoll[2]                
0C0D: 10@ 15 4 = 30.0         // fDirection[0]              
0C0D: 10@ 19 4 = 30.0         // fDirection[1]              
0C0D: 10@ 23 4 = 0.0         // fDirection[2]               
0C0D: 10@ 27 4 = 1@         // fPosition[0]                  
0C0D: 10@ 31 4 = 2@         // fPosition[1]                  
0C0D: 10@ 35 4 = 3@         // fPosition[2]                    
0C0D: 10@ 39 4 = -150.0      // fMoveSpeed[0]                 
0C0D: 10@ 43 4 = 150.0         // fMoveSpeed[1]               
0C0D: 10@ 47 4 = 5.0          // fMoveSpeed[2]               
0C0D: 10@ 51 4 = 300.0          // fTurnSpeed[0]            
0C0D: 10@ 55 4 = 300.0          // fTurnSpeed[1]         
0C0D: 10@ 59 4 = 0.0          // fTurnSpeed[2]   
0C0D: 10@ 63 4 = 190.0        // fHealth                Make it remain 190.0 so the car explodes so everyone know u r superman
to
alloc 10@ 67                 
0C0D: 10@ 0 2 = 12@              // Vehicle ID
0C0D: 10@ 2 1 = 1               // Seat ID         
0C0D: 10@ 3 4 = 0.0             // fRoll[0]         
0C0D: 10@ 7 4 = 0.0            // fRoll[1]             
0C0D: 10@ 11 4 = 0.0          // fRoll[2]                
0C0D: 10@ 15 4 = 0.0         // fDirection[0]              
0C0D: 10@ 19 4 = 0.0         // fDirection[1]              
0C0D: 10@ 23 4 = 0.0         // fDirection[2]               
0C0D: 10@ 27 4 = 1@         // fPosition[0]                  
0C0D: 10@ 31 4 = 2@         // fPosition[1]                  
0C0D: 10@ 35 4 = 3@         // fPosition[2]                    
0C0D: 10@ 39 4 = 60.0      // fMoveSpeed[0]                 
0C0D: 10@ 43 4 = 60.0         // fMoveSpeed[1]               
0C0D: 10@ 47 4 = 3.0          // fMoveSpeed[2]               
0C0D: 10@ 51 4 = 0.0          // fTurnSpeed[0]            
0C0D: 10@ 55 4 = 0.0          // fTurnSpeed[1]         
0C0D: 10@ 59 4 = 0.0          // fTurnSpeed[2]   
0C0D: 10@ 63 4 = 190.0        // fHealth                Make it remain 190.0 so the car explodes so everyone know u r superman
 

ra1z0

Active member
Joined
Mar 24, 2016
Messages
31
Reaction score
0
can u make it maybe that the cars fly where my camera is looking cuz the cars go to N-E almost al lthe time i found how to make it slower
 

0x32789

Expert
Joined
May 26, 2014
Messages
849
Reaction score
51
Location
LongForgotten <-> 0x32789
U can do it using my get/set camera rotation snippet
first get camera rotation then
5@ (or any variable) = sin camera rotation
and 6@ = cos samera rotation
then multiply both by 1000 and u send it with the new moveSpeedX and Y which is 5@ and 6@
 
Status
Not open for further replies.
Top