Exit house command
#1

Hello Everyone,

I've downloaded a house script because I can't make one by myself (I am a beginner) I am trying to make an exit house command but I cant find how to:
Quote:

// This function is used to spawn back at the entrance of your house
command:exit(playerid,HouseID)
House_Exit(playerid, HouseID)
{
// Set the player in the normal world again
SetPlayerVirtualWorld(playerid, 0);
SetPlayerInterior(playerid, 0);
// Set the position of the player at the entrance of his house
SetPlayerPos(playerid, AHouseData[HouseID][HouseX], AHouseData[HouseID][HouseY], AHouseData[HouseID][HouseZ]);
// Also clear the tracking-variable to track in which house the player is
APlayerData[playerid][CurrentHouse] = 0;

// Check if there is a timer-value set for exiting the house (this timer freezes the player while the environment is being loaded)
if (ExitHouseTimer > 1000)
{
// Don't allow the player to fall
TogglePlayerControllable(playerid, 0);
// Let the player know he's frozen for 5 seconds
GameTextForPlayer(playerid, "Waiting for the environment to load", ExitHouseTimer, 4);
// Start a timer that will allow the player to fall again when the environment has loaded
SetTimerEx("House_ExitTimer", ExitHouseTimer, false, "ii", playerid, HouseID);
}

return 1;
}

Quote:

C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(2676) : error 020: invalid symbol name ""

I am a beginner so I don't know much about pawno etc.

Hopefully someone can help me out.
Reply
#2

Which is Line number 2676?
Reply
#3

Quote:
Originally Posted by SimpalK
Посмотреть сообщение
Which is Line number 2676?
command:exit(playerid,HouseID)
Reply
#4

Try this one?

CMD:exitarena(playerid, params[])
Reply
#5

sorry wrong code

CMD:exit(playerid, params[])
Reply
#6

Gives me more errors:
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(733) : error 017: undefined symbol "DialogSellHouse"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(1796) : error 017: undefined symbol "DialogSellHouse"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(1832) : error 017: undefined symbol "House_Exit"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(2095) : error 017: undefined symbol "House_Exit"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(2677) : error 017: undefined symbol "House_Exit"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(2680) : error 021: symbol already defined: "SetPlayerVirtualWorld"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(2683) : error 021: symbol already defined: "SetPlayerPos"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(2685) : error 010: invalid function or declaration
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(268 : error 010: invalid function or declaration
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(2691) : error 021: symbol already defined: "TogglePlayerControllable"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(2693) : error 021: symbol already defined: "GameTextForPlayer"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(2695) : error 021: symbol already defined: "SetTimerEx"
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(269 : error 010: invalid function or declaration
C:\Users\eigenaar\Documenten\Pawno\filterscripts\U ntitled.pwn(3220) : warning 203: symbol is never used: "ExitHouseTimer"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


13 Errors.
Reply
#7

Anyone knows the solution??
Reply
#8

You can't bump until 24 hours. Define your dialogs. Remove the stuff that has more than one of, such as commands, or symbols etc. Make sure there's correct closing braces, indenting properly helps.

EDIT: this looks like PPC_Housing. correct?
Reply
#9

Quote:
Originally Posted by DobbysGamertag
Посмотреть сообщение
You can't bump until 24 hours. Define your dialogs. Remove the stuff that has more than one of, such as commands, or symbols etc. Make sure there's correct closing braces, indenting properly helps.

EDIT: this looks like PPC_Housing. correct?

Yes this is PPC but if I remove those things nothing works...
Reply
#10

Quote:
Originally Posted by -Shifty-
Посмотреть сообщение
Yes this is PPC but if I remove those things nothing works...
I thought it already had an exit house command?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)