Go Back   The Palace Avatar Chat Community Forums. > Palace Builders Palace Users > Scripting Help

Scripting Help Iptscrae et omni potentum, Scripting is all powerfull. So here you can ask for Help with your scripting problems.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 02-19-2007, 07:06 PM
PleasureMaster's Avatar
Palace User
 
Join Date: Feb 2007
Posts: 13
Rep Power: 0
PleasureMaster is on a distinguished road
Icon8 need a return script please

I am looking for a sr script or a return script that makes the person exit the room quickly and return quickly so they will show on top of other avs in the room if possible would like this script to be global so it will work from any room not just the gate for instance the room i am in when i type the command example: sr i will return to that same room
Reply With Quote
  #2 (permalink)  
Old 02-20-2007, 01:45 AM
Finna's Avatar
Super Moderator
 
Join Date: Mar 2006
Location: MO, USA
Posts: 55
Rep Power: 6
Finna is on a distinguished road
are you on a hosted server or a private pserver?
__________________
If all the worlds a stage, who handles the rewrites?
Reply With Quote
  #3 (permalink)  
Old 02-20-2007, 05:15 AM
PleasureMaster's Avatar
Palace User
 
Join Date: Feb 2007
Posts: 13
Rep Power: 0
PleasureMaster is on a distinguished road
private or hosted

i am on a private server at the moment windows pserver but i am moving to a hosted server as soon as i am done building.... i think you may be gonna tell me there is a plugin for it on hosted servers. am i correct? if so thats fine i will wait till i am hosted to have "return" but would still like a copy of the script as i am always messing around with test palaces on my pserver.

ty for all your help :))
Reply With Quote
  #4 (permalink)  
Old 02-20-2007, 05:38 AM
Finna's Avatar
Super Moderator
 
Join Date: Mar 2006
Location: MO, USA
Posts: 55
Rep Power: 6
Finna is on a distinguished road
well it is part of the plugall but there is also a script

this part would go in your gate script

; return (rapid exit and return to same room, available in all rooms)
returnToRm GLOBAL returnRm GLOBAL
{
{ roomID returnRm = 1002 GoToRoom } ChatStr "return" == IF
} returnToRm Def

just change the room number to what you want as well as the word return ( ChatStr "return" == IF)
to which ever command you wish to use

then this part has to be in your room globals in ON OUTCHAT

returnToRm GLOBAL returnRm GLOBAL returnToRm EXEC


this script will only work in the rooms the globals are in, if you have need of a complete gate script and globals let me know.

put this script in the return room itself it allows you to enter the room with the name fixScript in order to do things like up or down list if you ever need to move it

ON ENTER { returnToRm GLOBAL returnRm GLOBAL
{ returnRm GoToRoom } UserName "fixScript" == NOT IF
}
__________________
If all the worlds a stage, who handles the rewrites?
Reply With Quote
  #5 (permalink)  
Old 02-21-2007, 08:35 PM
PleasureMaster's Avatar
Palace User
 
Join Date: Feb 2007
Posts: 13
Rep Power: 0
PleasureMaster is on a distinguished road
return script trouble

i am having trouble with the return script i have made a cloud room as the bounce room and put these 2 scripts in there in seperate doors

ON SIGNON { 86 GOTOROOM }
ON OUTCHAT { pmc GLOBAL 0 pmc EXEC }
{ returnToRm GLOBAL returnRm GLOBAL returnToRm EXEC }
ON INCHAT { pmc GLOBAL 1 pmc EXEC }
ON ENTER { pmc GLOBAL 2 pmc EXEC }
ON LEAVE { pmc GLOBAL 3 pmc EXEC
{ PAINTCLEAR CLEARLOOSEPROPS } NBRROOMUSERS 2 < IF
}

not sure if the return part is in there correctly


also this script is in there

ON ENTER { returnToRm GLOBAL returnRm GLOBAL
{ returnRm GoToRoom } UserName "fixScript" == NOT IF
}

i dont think the second one is the problem

here is my gate script with the return script added in not sure if it is right

ON SIGNON { pmc GLOBAL
{ hnd =
{
;offer/accept outchat part
accav GLOBAL
{ 0 cr = ";offav " av =
{ av " " & cr USERPROP ITOA & av = cr ++ }
{ cr NBRUSERPROPS < } WHILE
av CHATSTR = "I am offering you this av. Say accept to take it." WHOTARGET PRIVATEMSG
} CHATSTR "offer" == WHOTARGET AND IF
{ { "" CHATSTR = accav " SETPROPS " & STRTOATOM EXEC } CHATSTR "accept" == IF
} accav 0 == NOT IF
;room goto script
{ rd =
{ "" CHATSTR = rd 0 GET GOTOROOM
} rd 1 GET CHATSTR == IF
} [
[ 86 "gate" ]
[ 91 "ndupe" ]
[ 2662 "pdupe" ]
[ 105 "gindex" ]
[ 113 "sgate" ]
[ 114 "pm1" ]
[ 804 "brbz" ]
[ 7 "directory" ]
[ 93 "avatar" ]
[ 100 "borgs" ]
[ 130 "links" ]
[ 128 "games" ]
[ 107 "music" ]
[ 392 "onchat2" ]
[ 99 "cb1" ]
] FOREACH
} 0 hnd == IF ;outchat handler
{
;offer/accept inchat part
accav GLOBAL
{ "[ $1 ]" GREPSUB acv =
{ acv accav =
} acv STRTOATOM EXEC LENGTH DUP 10 < AND IF
} CHATSTR "^;offav ([ 0-9-]+)$" GREPSTR WHOCHAT WHOME != AND IF
{
{ { "$1" GREPSUB STRTOATOM EXEC
} CHATSTR "^;ao (.*)" GREPSTR IF
} WHOCHAT WHOME == NOT IF
{ "$1" GREPSUB STRTOATOM EXEC
} CHATSTR "^;allscray (.*)" GREPSTR IF
{ dpn GLOBAL 1 dpn = 333 GOTOROOM
} CHATSTR "chill" == ISWIZARD NOT AND IF
} WHOCHAT WHONAME "^[*]" GREPSTR IF
} 1 hnd == IF ;inchat handler
{
} 2 hnd == IF ;enter handler
{
} 3 hnd == IF ;leave handler
} pmc DEF
icamefrom GLOBAL
{ "" icamefrom = } icamefrom 0 == IF
"'page has logged on"
{ " from " icamefrom + + } icamefrom "." GREPSTR IF
" as user number " whome itoa + +
{ " with an unregistered client." + } ISGUEST IF
SAY servername icamefrom =
dpn GLOBAL
{ 333 GOTOROOM } dpn IF
}
{
; return (rapid exit and return to same room, available in all rooms)
returnToRm GLOBAL returnRm GLOBAL
{
{ roomID returnRm = 805 GoToRoom } ChatStr "sr" == IF
;change the 1002 to the room number of your return room
} returnToRm Def
}

notice the room id is 805 thats the ID for the cloud room aka bounce room
is that correct
thank you for your help smiles
Reply With Quote
  #6 (permalink)  
Old 02-21-2007, 11:56 PM
Finna's Avatar
Super Moderator
 
Join Date: Mar 2006
Location: MO, USA
Posts: 55
Rep Power: 6
Finna is on a distinguished road
ok looking it all over the only change I can see that needs to be made is in the room globals

Quote: Originally Posted by
ON SIGNON { 86 GOTOROOM }
ON OUTCHAT { pmc GLOBAL 0 pmc EXEC }
{ returnToRm GLOBAL returnRm GLOBAL returnToRm EXEC }
ON INCHAT { pmc GLOBAL 1 pmc EXEC }
ON ENTER { pmc GLOBAL 2 pmc EXEC }
ON LEAVE { pmc GLOBAL 3 pmc EXEC
{ PAINTCLEAR CLEARLOOSEPROPS } NBRROOMUSERS 2 < IF
}
ON OUTCHAT { pmc GLOBAL 0 pmc EXEC
returnToRm GLOBAL returnRm GLOBAL returnToRm EXEC
}
__________________
If all the worlds a stage, who handles the rewrites?
Reply With Quote
  #7 (permalink)  
Old 02-22-2007, 01:51 PM
PleasureMaster's Avatar
Palace User
 
Join Date: Feb 2007
Posts: 13
Rep Power: 0
PleasureMaster is on a distinguished road
still does not work

ok here is what i have changed after ur last reply

in 2 of the doors at gate there is these 2 scripts
id1

ON SIGNON { pmc GLOBAL
{ hnd =
{
;offer/accept outchat part
accav GLOBAL
{ 0 cr = ";offav " av =
{ av " " & cr USERPROP ITOA & av = cr ++ }
{ cr NBRUSERPROPS < } WHILE
av CHATSTR = "I am offering you this av. Say accept to take it." WHOTARGET PRIVATEMSG
} CHATSTR "offer" == WHOTARGET AND IF
{ { "" CHATSTR = accav " SETPROPS " & STRTOATOM EXEC } CHATSTR "accept" == IF
} accav 0 == NOT IF
;room goto script
{ rd =
{ "" CHATSTR = rd 0 GET GOTOROOM
} rd 1 GET CHATSTR == IF
} [
[ 86 "gate" ]
[ 91 "ndupe" ]
[ 2662 "pdupe" ]
[ 105 "gindex" ]
[ 113 "sgate" ]
[ 114 "pm1" ]
[ 804 "brbz" ]
[ 7 "directory" ]
[ 93 "avatar" ]
[ 100 "borgs" ]
[ 130 "links" ]
[ 128 "games" ]
[ 107 "music" ]
[ 392 "onchat2" ]
[ 99 "cb1" ]
] FOREACH
} 0 hnd == IF ;outchat handler
{
;offer/accept inchat part
accav GLOBAL
{ "[ $1 ]" GREPSUB acv =
{ acv accav =
} acv STRTOATOM EXEC LENGTH DUP 10 < AND IF
} CHATSTR "^;offav ([ 0-9-]+)$" GREPSTR WHOCHAT WHOME != AND IF
{
{ { "$1" GREPSUB STRTOATOM EXEC
} CHATSTR "^;ao (.*)" GREPSTR IF
} WHOCHAT WHOME == NOT IF
{ "$1" GREPSUB STRTOATOM EXEC
} CHATSTR "^;allscray (.*)" GREPSTR IF
{ dpn GLOBAL 1 dpn = 333 GOTOROOM
} CHATSTR "chill" == ISWIZARD NOT AND IF
} WHOCHAT WHONAME "^[*]" GREPSTR IF
} 1 hnd == IF ;inchat handler
{
} 2 hnd == IF ;enter handler
{
} 3 hnd == IF ;leave handler
} pmc DEF
icamefrom GLOBAL
{ "" icamefrom = } icamefrom 0 == IF
"'page has logged on"
{ " from " icamefrom + + } icamefrom "." GREPSTR IF
" as user number " whome itoa + +
{ " with an unregistered client." + } ISGUEST IF
SAY servername icamefrom =
dpn GLOBAL
{ 333 GOTOROOM } dpn IF }
{
; return (rapid exit and return to same room, available in all rooms)
returnToRm GLOBAL returnRm GLOBAL
{
{ roomID returnRm = 805 GoToRoom } ChatStr "sr" == IF
;change the 805 to the room number of your return room
} returnToRm Def
}

in a seperate door is this id2

;ON SIGNON { 86 GOTOROOM }
ON OUTCHAT { pmc GLOBAL 0 pmc EXEC
returnToRm GLOBAL returnRm GLOBAL returnToRm EXEC
}
ON INCHAT { pmc GLOBAL 1 pmc EXEC }
ON ENTER { pmc GLOBAL 2 pmc EXEC }
ON LEAVE { pmc GLOBAL 3 pmc EXEC
{ PAINTCLEAR CLEARLOOSEPROPS } NBRROOMUSERS 2 < IF
}

here is the room info on the gate maybe another script is messing it up i know the rest r working scripts they r from my old pat file which was years old

Room number: 86
Room name: P£ë@§ürë'§ Gate
Number of spots: 7
Spot id: Spot state: Spot Destination: Spot name:
1 0 0 main palace script
2 0 7 main direct link
3 0 0 global_w/ac
4 0 0 welcome script/help
5 0 804 brb&mouseover scr.
6 0 113 main 2 sgate link
7 0 0 brb timer

these 2 and only these 2 r in the return room


ON SIGNON { 86 GOTOROOM }
ON OUTCHAT { pmc GLOBAL 0 pmc EXEC
returnToRm GLOBAL returnRm GLOBAL returnToRm EXEC
}
ON INCHAT { pmc GLOBAL 1 pmc EXEC }
ON ENTER { pmc GLOBAL 2 pmc EXEC }
ON LEAVE { pmc GLOBAL 3 pmc EXEC
{ PAINTCLEAR CLEARLOOSEPROPS } NBRROOMUSERS 2 < IF
}


ON ENTER { returnToRm GLOBAL returnRm GLOBAL
{ returnRm GoToRoom } UserName "fixScript" == NOT IF
}

room info:

Room name: Return Room
Number of spots: 2
Spot id: Spot state: Spot Destination: Spot name:
1 0 0 fixscript
2 0 0 global

I hope this is enuff info to fix this problem crosses fingers
ty again :))
Reply With Quote
  #8 (permalink)  
Old 02-22-2007, 03:06 PM
Finna's Avatar
Super Moderator
 
Join Date: Mar 2006
Location: MO, USA
Posts: 55
Rep Power: 6
Finna is on a distinguished road
ok this is the entire gate script I have with the information from yours already added, this all goes in one door on the gate, then the bottem parts (from ON ENTER through ON LEAVE) go in each room for your room globals


ON SIGNON {
;
;ICameFrom Script
ICameFrom GLOBAL Instpal GLOBAL
MOUSEPOS + 0 == Instpal =
Mac GLOBAL PC GLOBAL
{ 1 Mac = } { 1 PC = } DATETIME 0 < IFELSE
{
{ " PC" ctype = } CLIENTTYPE "WINDOWS32" == IF
{ " Mac" ctype = } CLIENTTYPE "MACPPC" == IF
{ " TPV" ctype = } CLIENTTYPE "TPV" == IF
}
{
{ "n InstantPalace" ctype = }
{
{ " PC (old version)" ctype = } 1 PC == IF
{ " Mac (old version)" ctype = } 1 Mac == IF
} Instpal IFELSE
} IPTVERSION IFELSE
{ { "nowhere" ICameFrom = } ICameFrom VARTYPE SWAP POP 4 <> IF CLIENTTYPE }
{ { "nowhere" ICameFrom = } 0 ICameFrom == IF } IPTVERSION IFELSE
"`page )boom I'm a" { { "n unregistered" & } ISGUEST IF } Instpal NOT IF
ctype & " user from " & ICameFrom & ". Visitor #" & WhoMe ITOA & " since last restart." & SAY
ServerName " (your addy:9998} " & ICameFrom =
;
; offer/accept script
offeredAvatar GLOBAL offerInScript GLOBAL offerOutScript GLOBAL
{ offeredAvatar GLOBAL prps GLOBAL
{ "$1" GREPSUB prps =
{ "[ " prps & " ] SETPROPS" & offeredAvatar =
"@" WHOCHAT WHOPOS ITOA SWAP ITOA "," & SWAP & &
" You have been offered an avatar by " & WHOCHAT WHONAME &
". To accept it, type \"accept\"." & LOCALMSG }
prps ".* .* .* .* .* .* .* .* .* .*" GREPSTR NOT
prps "-$" GREPSTR NOT AND
prps "- " GREPSTR NOT AND
prps ">$" GREPSTR NOT AND
prps "> " GREPSTR NOT AND
prps "<$" GREPSTR NOT AND
prps "< " GREPSTR NOT AND WHOCHAT WHOME <> AND IF
"" CHATSTR = } CHATSTR "^;avoffer [\[] ([0-9<>A-Fa-f -]+) [\]]" GREPSTR IF
} offerInScript DEF
;
{ offeredAvatar GLOBAL
{ { {
0 i = ";avoffer [ "
{ i USERPROP ITOA & " " & i ++ } { i NBRUSERPROPS < } WHILE "]" &
WHOTARGET PRIVATEMSG } NBRUSERPROPS IF }
{ "You have to whisper the offer." STATUSMSG } WHOTARGET IFELSE
"" CHATSTR = } CHATSTR "offer" == IF
;
{ "" CHATSTR = offeredAvatar STRTOATOM EXEC
} "accept" CHATSTR == "\"accept\"" CHATSTR == OR offeredAvatar "" <> AND IF
{ "" CHATSTR = } CHATSTR "^;avoffer" GREPSTR IF
} offerOutScript DEF
;
; Allscray script
xDoIt GLOBAL nDoIt GLOBAL
{
{ "$1" GREPSUB STRTOATOM EXEC } CHATSTR "^;*allscray (.*)" GREPSTR IF
{ "$1" GREPSUB STRTOATOM EXEC } CHATSTR "^;as (.*)" GREPSTR IF
{ "$1" GREPSUB STRTOATOM EXEC } CHATSTR "^;ao (.*)" GREPSTR WHOCHAT WHOME == NOT AND IF
} xDoIt DEF
;
{ xDoIt GLOBAL
{ xDoIt EXEC } WhoChat WhoName "^[*]" GrepStr IF
} nDoIt DEF
;
;allscraycommands
allscraycommands GLOBAL
{
;gothere - send to mouse position
{ ";ao " MOUSEPOS SWAP ITOA " " & SWAP ITOA & & " SETPOS" & CHATSTR =
} CHATSTR "gothere" == IF
;sendroom - send to another room
{ ";ao $1 GOTOROOM" GREPSUB CHATSTR =
} CHATSTR LOWERCASE "sendroom ([0-9]*)" GREPSTR IF
;ghost - see if the person has poofed
{ ";ao \"I'm still here.\" WHOCHAT PRIVATEMSG" CHATSTR =
} CHATSTR "ghost" == IF
} allscraycommands DEF
;
; return (rapid exit and return to same room, available in all rooms)
returnToRm GLOBAL returnRm GLOBAL
{
{ roomID returnRm = 805 GoToRoom } ChatStr "sr" == IF
} returnToRm Def
;
; roomChange (key words / shortcuts used to go to other rooms, available in all rooms)
roomChange GLOBAL
{
{ "$1" GREPSUB pw =
{ dta =
{ "" ChatStr = dta 0 GET GOTOROOM } pw dta 1 GET == IF
}
[ ;just add room IDs and keywords as shown here
[ 86 "gate" ]
[ 91 "ndupe" ]
[ 2662 "pdupe" ]
[ 105 "gindex" ]
[ 113 "sgate" ]
[ 114 "pm1" ]
[ 804 "brbz" ]
[ 7 "directory" ]
[ 93 "avatar" ]
[ 100 "borgs" ]
[ 130 "links" ]
[ 128 "games" ]
[ 107 "music" ]
[ 392 "onchat2" ]
[ 99 "cb1" ]
] FOREACH
} CHATSTR "^(.*)$" GREPSTR IF
} roomChange DEF
;
; roomCommands (lists commands in user's log, available in all rooms)
roomCommands GLOBAL
{
{ "
ROOM COMMANDS" STATUSMSG
"To go to Type
Gate gate
SR to re-enter room
Lock room lock
Unlock room unlock
Dim lights dim 1 - dim 10
" LOGMSG
"Look in your log for Room Commands" STATUSMSG
"" ChatStr = } ChatStr "commands" == IF
} roomCommands DEF
;
;operatorCommands (useful lists for wizzes, available in all rooms )
operatorCommands GLOBAL
{
{
{ "`glist -k" SAY "" CHATSTR = } CHATSTR "ll" == IF
{ "`glist -o" SAY "" CHATSTR = } CHATSTR "oo" == IF
{ "`glist -p" SAY "" CHATSTR = } CHATSTR "ss" == IF
} ISWIZARD IF
} operatorCommands DEF
;
;script to dim room lighting
dimmer GLOBAL
{
{"$1" "0" & GREPSUB lev =
"\")\" lev ATOI DimRoom\" Say" StrToAtom Exec
"" ChatStr = } CHATSTR "^dim (.*)" GrepStr IF
} dimmer DEF
;
;provide general information to user
informationMsgs GLOBAL
{
{"The Owners of " ServerName & " are *your name here*." & LOCALMSG ""CHATSTR = } CHATSTR "God" ==IF
;
{"Head Wizz is: type name here." LOCALMSG ""CHATSTR = } CHATSTR "Wiz" ==IF
;
{"type rules here" LOCALMSG ""CHATSTR = } CHATSTR "rules" == IF
;
{
{ "@512,0 Want to give an av to someone? Whisper `OFFER to them. To recieve the av, type in: `ACCEPT." LOCALMSG } 10 ALARMEXEC
{ "@512,0 Type TRANSLATOR to open a website for a tranlator program.!!!" LOCALMSG } 600 ALARMEXEC
"" CHATSTR = } CHATSTR "4help" == IF
} informationMsgs DEF
;
;prop clear on exit
propclearer GLOBAL
{
{ PAINTCLEAR CLEARLOOSEPROPS } NBRROOMUSERS 1 <= IF
} propclearer DEF
;
; enterGreeting (on enter greeting given in all rooms )
enterGreeting GLOBAL
{ "See Log for more information." LocalMsg
"@10,10 If lock is visible, click on it Or Type \"Lock\" or \"Unlock\" to open or close the room." logmsg
"@180,10 Keywords for information are: Rules, God, Wiz, 4help, and Commands." LOGMSG
} enterGreeting DEF
}
;
ON ENTER {
enterGreeting GLOBAL enterGreeting Exec
}
;
ON INCHAT {
offerInScript GLOBAL offerInScript EXEC
dimmer GLOBAL dimmer EXEC
nDoIt GLOBAL nDoIt EXEC
dimmer GLOBAL dimmer EXEC
}
;
ON OUTCHAT {
offerOutScript GLOBAL offerOutScript EXEC
roomChange GLOBAL roomChange EXEC
roomCommands GLOBAL roomCommands EXEC
informationMsgs GLOBAL informationMsgs EXEC
operatorCommands GLOBAL operatorCommands EXEC
allscraycommands GLOBAL allscraycommands EXEC
returnToRm GLOBAL returnRm GLOBAL returnToRm EXEC
}
;
ON LEAVE { propclearer GLOBAL propclearer EXEC }
__________________
If all the worlds a stage, who handles the rewrites?

Last edited by Finna; 02-22-2007 at 03:22 PM.
Reply With Quote
  #9 (permalink)  
Old 02-22-2007, 06:46 PM
PleasureMaster's Avatar
Palace User
 
Join Date: Feb 2007
Posts: 13
Rep Power: 0
PleasureMaster is on a distinguished road
still not working getting frustrated

can I perhaps send u a copy of my pat file when i added the scripts to may gate i loose several doors in the gate plus the next 2 rooms i have lookd but i dont see what is causing it. ty once again :))
Reply With Quote
  #10 (permalink)  
Old 02-22-2007, 06:48 PM
PleasureMaster's Avatar
Palace User
 
Join Date: Feb 2007
Posts: 13
Rep Power: 0
PleasureMaster is on a distinguished road
contact info

here is my email and my msn id u_excite_me@hotmail.com if you want to send through msn messenger thats fine ty :))
Reply With Quote
Reply
Thread Tools
Display Modes

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
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Log Window does not recognize text return. coeurdeverre User Questions 7 03-28-2004 05:40 PM
Return of the King Premier Party at Middle Earth! Nimue Event announcements. 0 12-16-2003 06:26 PM

The Latest Posts
Title, Username, & Date Last Post Forum
download
03-21-2011 11:20 AM
by maarten
User Questions
Palace for Mac OS 10.6?
03-13-2011 09:39 AM
by pawnipt
User Questions
Server
03-07-2011 04:52 PM
by satinrose
User Questions
Return room Script
02-24-2011 12:07 AM
by jaela
Room Scripts
Releasing source code
02-17-2011 09:19 AM
by Sman�
Developers Forum
Website spammers
01-26-2011 08:48 PM
by maarten
The Planet: Palace News
Online Users: 66
1 members and 65 guests
VeraFlorsewal
Most users ever online was 1,010, 06-27-2007 at 11:45 PM.
Stats
Members: 5,112
Threads: 1,141
Posts: 4,004
Top Poster: maarten (1,169)
Welcome to our newest member, cliffymayers


All times are GMT +2. The time now is 03:04 PM.


Powered by vBulletin
Copyright ©2000 - 2011, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0