Raised This Month: $ Target: $400
 0% 

Unable to detect entity touch


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Kia
AlliedModders Donor
Join Date: Apr 2010
Location: In a world of madness
Old 07-24-2013 , 09:22   Unable to detect entity touch
Reply With Quote #1

Hello everybody,

I try to make the jumppads from Ricochet Maps working in Counter-Strike using this code here :

PHP Code:
public pfn_touch(ptrptd)
{
    
client_print(ptdprint_chat"Touch detected!")
    new 
szClassname[32]
    
entity_get_string(ptrEV_SZ_classnameszClassname31)
    
    if(
equali(szClassname,"trigger_jump"))
    {
        
client_print(0print_chat"Touched trigger_jump")
        new 
Float:velocity[3];
    
        
entity_get_vector(ptdEV_VEC_velocityvelocity);
        
velocity[2] = 500.0;                
        
entity_set_vector(ptdEV_VEC_velocityvelocity);
    
        
entity_set_int(ptdEV_INT_gaitsequence6);  
    }

But it always shows me only the first message, the second gets never called.
This Code proofs that they are trigger_jump entitys.

PHP Code:
public func_SearchEntity(id)
{
    new 
ent = -1
    
while((ent find_ent_by_class(ent"trigger_jump")))
    {
        
client_print(idprint_chat"trigger_jump found!")
    }

Anyone knows what I'm doing wrong?
__________________
Kia is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-24-2013 , 09:26   Re: Unable to detect entity touch
Reply With Quote #2

Show entity creation.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Kia
AlliedModders Donor
Join Date: Apr 2010
Location: In a world of madness
Old 07-24-2013 , 09:37   Re: Unable to detect entity touch
Reply With Quote #3

Entity is already at map.
Attached Files
File Type: zip rc_deathmatch.zip (83.9 KB, 47 views)
__________________
Kia is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-24-2013 , 09:50   Re: Unable to detect entity touch
Reply With Quote #4

And trigger_jump exist byu default in counter-strike ?
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Kia
AlliedModders Donor
Join Date: Apr 2010
Location: In a world of madness
Old 07-24-2013 , 11:46   Re: Unable to detect entity touch
Reply With Quote #5

No. I tried using BSP Compat Plugin to change name, but also didn't work.
__________________
Kia is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-24-2013 , 15:45   Re: Unable to detect entity touch
Reply With Quote #6

What entity replacement have you put ?

Try some existing trigger_***

Problem may be solid properties that is SOLID_NOT, or can be size that is too small, check it.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Kia
AlliedModders Donor
Join Date: Apr 2010
Location: In a world of madness
Old 07-24-2013 , 16:06   Re: Unable to detect entity touch
Reply With Quote #7

I replaced it with rc_jump, but also didn't work. Using BSPViewer shows me a small box at the entity, but it should be big enough.

How do I check if the entity is solid? Maybe I should say that the entity is invisible.
__________________
Kia is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-25-2013 , 02:31   Re: Unable to detect entity touch
Reply With Quote #8

rendering has no importance here
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Kia
AlliedModders Donor
Join Date: Apr 2010
Location: In a world of madness
Old 07-25-2013 , 03:09   Re: Unable to detect entity touch
Reply With Quote #9

func_wall is working, trigger_jump isn't.
__________________
Kia 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 06:28.


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