tezpull666
Banned
Posts: 286
Threads: 15
Joined: May 2013
|
Script help! 2
I did all the scripting:
OnStart() { AddUseItemCallback("", "key_study_1", "level_wood_1", "FUNCTION", true); }
OnEnter() {
}
OnLeave() {
}
void FUNCTION(string &in asItem, string &in asEntity) { SetLevelDoorLocked("level_wood_1", false); PlaySoundAtEntity("", "unlock_door.snt", asEntity, 0, false); RemoveItem("key_study_1"); }
But it said this:
Help2
(This post was last modified: 07-17-2013, 07:22 PM by tezpull666.)
|
|
07-17-2013, 07:04 PM |
|
OriginalUsername
Posting Freak
Posts: 896
Threads: 42
Joined: Feb 2013
Reputation:
34
|
RE: Script help! 2
You forgot to add void before OnStart. So it should be
Same for the OnLeave and OnEnter
|
|
07-17-2013, 07:06 PM |
|
tezpull666
Banned
Posts: 286
Threads: 15
Joined: May 2013
|
RE: Script help! 2
(07-17-2013, 07:06 PM)Smoke Wrote: You forgot to add void before OnStart. So it should be
Same for the OnLeave and OnEnter Thanks!
|
|
07-17-2013, 07:20 PM |
|
Icaab2608
Member
Posts: 85
Threads: 37
Joined: Jul 2013
Reputation:
0
|
RE: Script help! 2
(07-17-2013, 07:04 PM)Mike1265 Wrote: I did all the scripting:
OnStart() { AddUseItemCallback("", "key_study_1", "level_wood_1", "FUNCTION", true); }
OnEnter() {
}
OnLeave() {
}
void FUNCTION(string &in asItem, string &in asEntity) { SetLevelDoorLocked("level_wood_1", false); PlaySoundAtEntity("", "unlock_door.snt", asEntity, 0, false); RemoveItem("key_study_1"); }
But it said this:
Help2 OnStart() { AddUseItemCallback("", "key_study_1", "level_wood_1", "FUNCTION", true); } void FUNCTION(string &in asItem, string &in asEntity) { SetLevelDoorLocked("level_wood_1", false); PlaySoundAtEntity("", "unlock_door.snt", asEntity, 0, false); RemoveItem("key_study_1"); } OnEnter() {
}
OnLeave() {
}
|
|
07-18-2013, 07:58 AM |
|
PutraenusAlivius
Posting Freak
Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation:
119
|
RE: Script help! 2
I love that none of you actually give a shit about OnEnter() and OnLeave().
"Veni, vidi, vici."
"I came, I saw, I conquered."
|
|
07-18-2013, 08:07 AM |
|
OriginalUsername
Posting Freak
Posts: 896
Threads: 42
Joined: Feb 2013
Reputation:
34
|
RE: Script help! 2
(07-18-2013, 08:07 AM)JustAnotherPlayer Wrote: I love that none of you actually give a shit about OnEnter() and OnLeave().
He doesn't use them atm, right? Also, he might understand what they're doing and doesn't use them at all.
|
|
07-18-2013, 11:02 AM |
|
|