Raised This Month: $ Target: $400
 0% 

SM Parachute


Post New Thread Reply   
 
Thread Tools Display Modes
Soldinheaven
Junior Member
Join Date: Jan 2011
Old 02-24-2011 , 15:15   Re: SM Parachute
Reply With Quote #431

THE ONLY THING THAT THIS PLUGIN NEEDS IS "ADMIN FLAGS"
Soldinheaven is offline
Black Haze
BANNED
Join Date: Sep 2008
Location: Hamsterdam
Old 02-24-2011 , 20:07   Re: SM Parachute
Reply With Quote #432

Quote:
Originally Posted by Soldinheaven View Post
THE ONLY THING THAT THIS PLUGIN NEEDS IS "ADMIN FLAGS"
Plugin is no longer updated, download the source and have a go, it aint that hard. Just search around a bit on the forum.
Black Haze is offline
Soldinheaven
Junior Member
Join Date: Jan 2011
Old 02-25-2011 , 10:29   Re: SM Parachute
Reply With Quote #433

Quote:
Originally Posted by Black Haze View Post
Plugin is no longer updated, download the source and have a go, it aint that hard. Just search around a bit on the forum.
Thanks for info.
Soldinheaven is offline
eladnava
Member
Join Date: Feb 2011
Old 03-25-2011 , 12:33   Re: SM Parachute
Reply With Quote #434

Warning!

This plugin disables the effect of the !gravity command / SetEntityGravity. These functions will not have any effect and the gravity will stay at x1.0.

I will see if there is any way to make the two work together.


Edit: I found out why !gravity does not work with this mod. The mod has an OnGameFrame that keeps resetting the entity's gravity to 1.0 every game frame.

I edited the sm_parachute.sp to allow for SetEntityGravity() and the !gravity command to work, if you'd like to try it, please download the attachment. No this is not my mod, I just edited a few lines. If you find any problems, please let me know. I am using it in my server and it works great.
Attached Files
File Type: sp Get Plugin or Get Source (sm_parachute.sp - 1495 views - 19.3 KB)

Last edited by eladnava; 03-25-2011 at 14:54.
eladnava is offline
SWAT_88
SourceMod Donor
Join Date: Jan 2008
Location: Austria
Old 03-25-2011 , 15:36   Re: SM Parachute
Reply With Quote #435

Quote:
Originally Posted by eladnava View Post

This plugin disables the effect of the !gravity command / SetEntityGravity. These functions will not have any effect and the gravity will stay at x1.0.

I will see if there is any way to make the two work together.


Edit: I found out why !gravity does not work with this mod. The mod has an OnGameFrame that keeps resetting the entity's gravity to 1.0 every game frame.

I edited the sm_parachute.sp to allow for SetEntityGravity() and the !gravity command to work, if you'd like to try it, please download the attachment. No this is not my mod, I just edited a few lines. If you find any problems, please let me know. I am using it in my server and it works great.
The best way to achieve this would be, to remember the gravity of the player before pressing "E" and set it back after releasing "E". This solution would fix the gravity problem after using the parachute.

And no, I'm not setting the gravity every gameframe.
I only set it, while someone is holding the USE-button.
After releasing the USE-button, I set the gravity to 1.0.
So remembering the gravity and setting it back would be the best solution and would be compatible with all mods using different gravities.
__________________

Last edited by SWAT_88; 03-25-2011 at 19:44.
SWAT_88 is offline
eladnava
Member
Join Date: Feb 2011
Old 03-25-2011 , 17:59   Re: SM Parachute
Reply With Quote #436

Yes, that is what I did. I added an extra variable to store the gravity before and set it back to that gravity after the parachute.

However, I did notice an OnGameFrame with a Check() call, that had inside an if statement that said, if the client was on the ground, call EndPara(), which sets the gravity to 1.0. Maybe I misunderstood the code, but it would make sense as to why setting !gravity on a player would only have effect for one frame.

Last edited by eladnava; 03-25-2011 at 19:20.
eladnava is offline
SWAT_88
SourceMod Donor
Join Date: Jan 2008
Location: Austria
Old 03-25-2011 , 19:43   Re: SM Parachute
Reply With Quote #437

Quote:
Originally Posted by eladnava View Post
Yes, that is what I did. I added an extra variable to store the gravity before and set it back to that gravity after the parachute.

However, I did notice an OnGameFrame with a Check() call, that had inside an if statement that said, if the client was on the ground, call EndPara(), which sets the gravity to 1.0. Maybe I misunderstood the code, but it would make sense as to why setting !gravity on a player would only have effect for one frame.
You are totally right. I have overlooked the EndPara statement.
I have written this plugin a long time ago.
Thanks for looking at the code.

I can add a link to your post in my first post, if you want so.
__________________
SWAT_88 is offline
eladnava
Member
Join Date: Feb 2011
Old 03-26-2011 , 04:47   Re: SM Parachute
Reply With Quote #438

No problem man, your plugin is simply the best and a must-have for all servers of any kind. Any server that doesn't respond to 'e' when you jump just makes you want to leave it.

Thanks for your great mod!
eladnava is offline
Groger
Veteran Member
Join Date: Oct 2009
Location: Belgium
Old 03-26-2011 , 17:50   Re: SM Parachute
Reply With Quote #439

Quote:
Originally Posted by eladnava View Post
No problem man, your plugin is simply the best and a must-have for all servers of any kind. Any server that doesn't respond to 'e' when you jump just makes you want to leave it.

Thanks for your great mod!
I second that
Groger is offline
SWAT_88
SourceMod Donor
Join Date: Jan 2008
Location: Austria
Old 03-26-2011 , 18:12   Re: SM Parachute
Reply With Quote #440

Quote:
Originally Posted by Groger View Post
I second that
Quote:
Originally Posted by eladnava View Post
No problem man, your plugin is simply the best and a must-have for all servers of any kind. Any server that doesn't respond to 'e' when you jump just makes you want to leave it.

Thanks for your great mod!
You saved my day.
Thanks for the kind words.

Edit:
I have added a link to your post in my first post.
__________________

Last edited by SWAT_88; 03-26-2011 at 18:29.
SWAT_88 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 11:22.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode