Raised This Month: $ Target: $400
 0% 

pfn_touch


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Timmi the savage
Senior Member
Join Date: Jul 2004
Location: seattle
Old 09-02-2004 , 18:10   pfn_touch
Reply With Quote #1

Hi this is probally a simple question.
I was wondering why i cant pfn touch to work.

I want it to delete an entity (touched)
and then set a player (toucher) variable.

Heres what i got.
Timmi the savage is offline
Send a message via Yahoo to Timmi the savage
Timmi the savage
Senior Member
Join Date: Jul 2004
Location: seattle
Old 09-02-2004 , 18:17  
Reply With Quote #2

New WAY

#include <engine>
#include <fakemeta>
Code:
public pfn_touch( ptr , ptd )    //When two entites touch {                 new enttouch = ptr     new touchedid = ptd     new modelName[32]     pev(id, pev_classname, modelName )     //entity_get_string ( enttouch, EV_SZ_model, modelName, 31 )//     // used to be entity.     if ( containi( modelName, "leet.mdl" ) != -1 ) {           remove_entity( szentity[id] )           questitem1[id]=1           quest(id)     } }
Timmi the savage is offline
Send a message via Yahoo to Timmi the savage
Timmi the savage
Senior Member
Join Date: Jul 2004
Location: seattle
Old 09-02-2004 , 18:18  
Reply With Quote #3

Code:
#include <amxmodx> #include <amxmisc> #include <string> #include <engine> #include <fun> #include <cstrike>
Timmi the savage is offline
Send a message via Yahoo to Timmi the savage
Timmi the savage
Senior Member
Join Date: Jul 2004
Location: seattle
Old 09-02-2004 , 18:21  
Reply With Quote #4

The money.mdl is precached.

The problem im having is it crashes.
Just after map start
Timmi the savage is offline
Send a message via Yahoo to Timmi the savage
johnjg75
Veteran Member
Join Date: Mar 2004
Location: Delaware
Old 09-02-2004 , 18:30  
Reply With Quote #5

check the logs?
__________________
johnjg75 is offline
Send a message via AIM to johnjg75 Send a message via MSN to johnjg75 Send a message via Yahoo to johnjg75
Timmi the savage
Senior Member
Join Date: Jul 2004
Location: seattle
Old 09-02-2004 , 18:49  
Reply With Quote #6

Nothing in the logs?
Timmi the savage is offline
Send a message via Yahoo to Timmi the savage
johnjg75
Veteran Member
Join Date: Mar 2004
Location: Delaware
Old 09-02-2004 , 18:54  
Reply With Quote #7

hmm, full code?
__________________
johnjg75 is offline
Send a message via AIM to johnjg75 Send a message via MSN to johnjg75 Send a message via Yahoo to johnjg75
Timmi the savage
Senior Member
Join Date: Jul 2004
Location: seattle
Old 09-02-2004 , 18:57  
Reply With Quote #8

its 215k
http://forums.alliedmods.net/showthr...?p=50029#52715
here ffx mod
Timmi the savage is offline
Send a message via Yahoo to Timmi the savage
Twilight Suzuka
bad
Join Date: Jul 2004
Location: CS lab
Old 09-02-2004 , 21:20  
Reply With Quote #9

toucher is the ent, touched is the player, no matter what.
__________________
Twilight Suzuka is offline
Send a message via AIM to Twilight Suzuka Send a message via MSN to Twilight Suzuka
Timmi the savage
Senior Member
Join Date: Jul 2004
Location: seattle
Old 09-02-2004 , 22:09  
Reply With Quote #10

awsome thanks for clearing that up

also i noticed

Code:
pfn_touch(ptr,ptd)

i guess it has to be formated like that

When i was trying to figure i tried it like that and it still kept crashing.

I was trying to get it to make the entity dissapear and set a player variable. With help i can figure out how pfn_touch. Maybe stumble on to it. I dunno I got some time off and im trying to understand this more thuroughly. ANY HELP is appreciated
Timmi the savage is offline
Send a message via Yahoo to Timmi the savage
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 17:12.


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