Raised This Month: $ Target: $400
 0% 

Mafuba plugin still in need of help.....


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Celena Luna
Veteran Member
Join Date: Aug 2013
Location: Nagazora
Old 07-17-2018 , 12:47   Re: Mafuba plugin still in need of help.....
Reply With Quote #1

PHP Code:
register_touch"mafubaphase2""world""Mafubaphase2_touch"
The second param should always be "*" since it will check EVERYTHING touch it. You can choose which thing to do next after depend on what object/thing touch it by checking classname.

PHP Code:
if(!task_exists(ent+9999))
{
    
set_task(1.0"removeEntity"ent+9999); //Prevent from touching multiple time
    
set_task(2.0"Phase2"pev_owner); //Prevent from touching multiple time

pev_owner is not the id of the entity's owner. pev(ent, pev_owner) is the one.

PHP Code:
@CreateMafubaBeamEntityphase2(100pev_owner1.0100); 
The 1st param should be the where it return the entity's id not set entity's id
The 2nd param is the same problem I said about pev_owner above.
Param 3rd and 4th you are right.
__________________
My plugin:

Last edited by Celena Luna; 07-17-2018 at 12:49.
Celena Luna is offline
BANDIT228
Member
Join Date: Sep 2017
Old 07-17-2018 , 12:55   Re: Mafuba plugin still in need of help.....
Reply With Quote #2

i need that mafubaphase2 detects when it collides with world and entity mafuba_jar

how do i detect the world in the second touch? with a && entity mafuba jar it should do the trick.


@CreateMafubaBeamEntityphase2(100, pev_owner, 1.0, 100);
set_task(2.0, "Phase2", pev_owner); //Prevent from touching multiple time

==>

@CreateMafubaBeamEntityphase2(100, pev(ent, pev_owner), 1.0, 100);
set_task(2.0, "Phase2", pev(ent, pev_owner)); //Prevent from touching multiple time

that right?

and what about the entity error? as soon as the first entity (mafuba) touches the victim my console get spammed with "invalid entity"
even when i disabled all of the lines above
BANDIT228 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 12:29.


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