Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Unexpected err {
mrjoshy12 Offline
Junior Member

Posts: 8
Threads: 1
Joined: Jul 2013
Reputation: 0
#11
RE: Unexpected err {

(07-16-2013, 11:09 AM)No Author Wrote: The adduseitemcallback script on Lolkey_1 to loldoor_1 doesn't have a void before the "{"
Edit : I meant lol_key1 and lol_door1
i havent really learnt voids yet, i learnt most of it by a vid
but now its got very confusing
07-16-2013, 11:13 AM
Find
PutraenusAlivius Offline
Posting Freak

Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation: 119
#12
RE: Unexpected err {

(07-16-2013, 11:05 AM)mrjoshy12 Wrote: wow all these comments, i actually forgot to say i started doing this scripting yesterday,
so yeah i dont actually get what most of you are sayin

Just use the code.

"Veni, vidi, vici."
"I came, I saw, I conquered."
07-16-2013, 11:20 AM
Find
mrjoshy12 Offline
Junior Member

Posts: 8
Threads: 1
Joined: Jul 2013
Reputation: 0
#13
RE: Unexpected err {

(07-16-2013, 11:20 AM)JustAnotherPlayer Wrote:
(07-16-2013, 11:05 AM)mrjoshy12 Wrote: wow all these comments, i actually forgot to say i started doing this scripting yesterday,
so yeah i dont actually get what most of you are sayin

Just use the code.
it didnt work
(16, 1)
(21, 6) was the problem
07-16-2013, 11:22 AM
Find
PutraenusAlivius Offline
Posting Freak

Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation: 119
#14
RE: Unexpected err {

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
    SetSwingDoorLocked("escape_room_door1", false, true);
     PlaySoundAtEntity("", "unlock_door", "escape_room_door1", 0, false);
     RemoveItem("escape_door_key1");
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
    SetSwingDoorLocked("lol_door1", false, true);
     PlaySoundAtEntity("", "unlock_door", "lol_door1", 0, false);
     RemoveItem("lol_key1");
     PlayMusic("Without_You_.ogg", false, 1, 0, true);
}

Both functions have the same name.

"Veni, vidi, vici."
"I came, I saw, I conquered."
07-16-2013, 11:24 AM
Find
mrjoshy12 Offline
Junior Member

Posts: 8
Threads: 1
Joined: Jul 2013
Reputation: 0
#15
RE: Unexpected err {

(07-16-2013, 11:24 AM)JustAnotherPlayer Wrote:
void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
    SetSwingDoorLocked("escape_room_door1", false, true);
     PlaySoundAtEntity("", "unlock_door", "escape_room_door1", 0, false);
     RemoveItem("escape_door_key1");
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
    SetSwingDoorLocked("lol_door1", false, true);
     PlaySoundAtEntity("", "unlock_door", "lol_door1", 0, false);
     RemoveItem("lol_key1");
     PlayMusic("Without_You_.ogg", false, 1, 0, true);
}

Both functions have the same name.
oh, well thanks i'll try it

(07-16-2013, 11:24 AM)JustAnotherPlayer Wrote:
void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
    SetSwingDoorLocked("escape_room_door1", false, true);
     PlaySoundAtEntity("", "unlock_door", "escape_room_door1", 0, false);
     RemoveItem("escape_door_key1");
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
    SetSwingDoorLocked("lol_door1", false, true);
     PlaySoundAtEntity("", "unlock_door", "lol_door1", 0, false);
     RemoveItem("lol_key1");
     PlayMusic("Without_You_.ogg", false, 1, 0, true);
}

Both functions have the same name.
ok once i used it errors came up so i will stick with ma old one
(This post was last modified: 07-16-2013, 11:36 AM by mrjoshy12.)
07-16-2013, 11:27 AM
Find
No Author Offline
Posting Freak

Posts: 962
Threads: 10
Joined: Jun 2012
Reputation: 13
#16
RE: Unexpected err {

The same error again ?
07-16-2013, 11:38 AM
Find
mrjoshy12 Offline
Junior Member

Posts: 8
Threads: 1
Joined: Jul 2013
Reputation: 0
#17
RE: Unexpected err {

(07-16-2013, 11:38 AM)No Author Wrote: The same error again ?
yup, i just dont get it, i only know how to script the one item and nothing else, i need it more simplified oh and i just dont get voids, i found it on videos
(This post was last modified: 07-16-2013, 11:42 AM by mrjoshy12.)
07-16-2013, 11:39 AM
Find
No Author Offline
Posting Freak

Posts: 962
Threads: 10
Joined: Jun 2012
Reputation: 13
#18
RE: Unexpected err {

JustAnotherPlayer didn't change the script he gave, just so you know. You used "UseKeyOnDoor" script twice. That caused the error. You need to change it. And do some edit at the void OnStart.

And post the changed script and the error you got.
(This post was last modified: 07-16-2013, 11:48 AM by No Author.)
07-16-2013, 11:44 AM
Find
The chaser Offline
Posting Freak

Posts: 2,486
Threads: 76
Joined: Jun 2012
Reputation: 113
#19
RE: Unexpected err {

////////////////////////////

// This runs when the player enters the map

void OnEnter()

{

     AddUseItemCallback("", "escape_door_key1", "escape_room_door1", "UsedKeyOnDoor", true);
AddUseItemCallback("", "lol_key1", "lol_door1", "UsedKeyOnDoor2", true);

}



void UsedKeyOnDoor(string &in asItem, string &in asEntity)

{

     SetSwingDoorLocked("escape_room_door1", false, true);

     PlaySoundAtEntity("", "unlock_door.snt", "escape_room_door1", 0, false);

     RemoveItem("escape_door_key1");

}



void UsedKeyOnDoor2(string &in asItem, string &in asEntity)

{

     SetSwingDoorLocked("lol_door1", false, true);

     PlaySoundAtEntity("", "unlock_door.snt", "lol_door1", 0, false);

     RemoveItem("lol_key1");

     PlayMusic("Without_You_.ogg", false, 1, 0, true);

}

//===========================================

// This runs when the player leaves the map

void OnLeave()

{

}

Does it cost much to simply fix the script? Here you have, this should be ok, without errors.

THE OTHERWORLD (WIP)
[Image: k6vbdhu]

Aculy iz dolan.
07-16-2013, 11:47 AM
Find
No Author Offline
Posting Freak

Posts: 962
Threads: 10
Joined: Jun 2012
Reputation: 13
#20
RE: Unexpected err {

(07-16-2013, 11:47 AM)The chaser Wrote: Does it cost much to simply fix the script?

Yes with my sucky phone that always stop working every 5 minutes
07-16-2013, 11:51 AM
Find




Users browsing this thread: 2 Guest(s)