Raised This Month: $ Target: $400
 0% 

Solved Bots to use a parachute


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Siska1
Senior Member
Join Date: Feb 2020
Location: BedRock
Old 04-08-2023 , 08:32   Re: Bots to use a parachute
Reply With Quote #11

Quote:
Originally Posted by DJEarthQuake View Post
Code:
/*����������*/ #include <amxmodx> #include <engine> #include <fakemeta> #include <fun> #define PLUGIN "Auto Null Parachute" #define VERSION "0.1" #define AUTHOR "SPiNX" #define MAX_AUTHID_LENGTH          64 #define MAX_IP_LENGTH              16 new pAutoDeploy, pFallSpeed, pParaModel, g_model; public plugin_init() {    register_plugin(PLUGIN, VERSION, AUTHOR);    pFallSpeed  = register_cvar("parachute_fallspeed", "100");    pAutoDeploy = register_cvar("parachute_autorip", "200");    pParaModel  = register_cvar("parachute_model", "1"); } public plugin_precache()    g_model = precache_model("sprites/steam1.spr"); public client_PreThink(id) {    if (is_user_connecting(id) || !is_user_connected(id) || !is_user_alive(id))       return;    else    {        new Rip_Cord = get_pcvar_num(pAutoDeploy);        new AUTO;        AUTO = (pev(id,pev_flFallVelocity) >= (get_pcvar_num(pFallSpeed) + Rip_Cord) );        new Float:fallspeed = get_pcvar_float(pFallSpeed) * -1.0        new button = get_user_button(id), oldbutton = get_user_oldbutton(id), flags = get_entity_flags(id);        if(flags & FL_ONGROUND)        {           if (get_user_gravity(id) == 0.1)              set_user_gravity(id, 1.0)           return        }        if(button & IN_USE|AUTO)        {           new Float:velocity[3]           entity_get_vector(id, EV_VEC_velocity, velocity)           set_user_gravity(id, 0.1)           velocity[2] = (velocity[2] + 40.0 < fallspeed) ? velocity[2] + 40.0 : fallspeed           if(get_pcvar_num(pParaModel))           {               entity_set_vector(id, EV_VEC_velocity, velocity)               emessage_begin( MSG_PVS, SVC_TEMPENTITY, { 0, 0, 0 }, 0 );               ewrite_byte(TE_PLAYERATTACHMENT)               ewrite_byte(id)               ewrite_coord(-MAX_AUTHID_LENGTH)               ewrite_short(g_model)               ewrite_short(MAX_IP_LENGTH) //life               emessage_end();           }        }        else if (oldbutton & IN_USE)           set_user_gravity(id, 1.0);     } }

Automatic null chute for both humans and bots. Custom waypoints were required for AI to jump down with Ping Of Death Bots.
Where can I find a parachute plugin that works for bots but with the parachute model. Because this one here shows some white cloud under the feet of the bots and they fly with it.
I'm looking for one that works with one model only for everyone and also works for bots.
The one with the three models doesn't work for bots and also crashes the server.
__________________

Last edited by Siska1; 04-08-2023 at 10:06.
Siska1 is offline
Send a message via Skype™ to Siska1
 



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 10:03.


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