| Mirage Source http://www.miragesource.net/forums/ |
|
| Can't get a case to work right. http://www.miragesource.net/forums/viewtopic.php?f=201&t=2602 |
Page 1 of 1 |
| Author: | Egon [ Sun Sep 02, 2007 12:32 am ] |
| Post subject: | Can't get a case to work right. |
Now, I just copied the /away case and edited it some. This should change the player name to " ", right? It doens't even respond when I type in "/ghost".. Code: Case "/ghost" 'If GetPlayerAccess(index) >= 1 Then If GetVar("accounts\" & GetPlayerLogin(index) & ".ini", "CHAR" & GetPlayerCharNum(index), "Ghost") = 0 Then Call PlayerMsg("Ghost mode active...", 14) Call PutVar("accounts\" & GetPlayerLogin(index) & ".ini", "CHAR" & GetPlayerCharNum(index), "Ghost", 1) Call PutVar("accounts\" & GetPlayerLogin(index) & ".ini", "CHAR" & GetPlayerCharNum(index), "TempPlayerName", GetPlayerName(index)) Call SetPlayerName(index, " ") Call SendPlayerData(index) Exit Sub ElseIf GetVar("accounts\" & GetPlayerLogin(index) & ".ini", "CHAR" & GetPlayerCharNum(index), "Ghost") = 1 Then Call SetPlayerName(index, GetVar("accounts\" & GetPlayerLogin(index) & ".ini", "CHAR" & GetPlayerCharNum(index), "TempPlayerName")) Call PlayerMsg("Ghost mode deactivated...", 14) Call PutVar("accounts\" & GetPlayerLogin(index) & ".ini", "CHAR" & GetPlayerCharNum(index), "Ghost", 0) Call SendPlayerData(index) Exit Sub End If 'End If I also want it to set the player sprite to, say, 0, which happens to be the null color. But I still have to figure that out. Code: Call SetPlayerSprite(Index, 0) ?Edit: Now "/away" doesn't even respond o.O |
|
| Author: | Rezeyu [ Sun Sep 02, 2007 12:39 am ] |
| Post subject: | Re: Can't get a case to work right. |
Where is this in your source? I've never added the /away tut. =/ |
|
| Author: | Egon [ Sun Sep 02, 2007 1:00 am ] |
| Post subject: | Re: Can't get a case to work right. |
It's in my Scripts folder under Main. |
|
| Author: | Rezeyu [ Sun Sep 02, 2007 2:47 am ] |
| Post subject: | Re: Can't get a case to work right. |
Oh, Elysium. |
|
| Author: | Lea [ Sun Sep 02, 2007 4:11 am ] |
| Post subject: | Re: Can't get a case to work right. |
I'd recommend going to Elysium for support on Elysium software. We do NOT support it here. |
|
| Author: | Matt [ Sun Sep 02, 2007 1:34 pm ] |
| Post subject: | Re: Can't get a case to work right. |
Elysium is crap. xD We'll help you out if you're adding something in that you're coding yourself, or if you need general help coding and such, but when it comes to current ES code/tutorials, I'd rather not have anything to do with it. You really should switch to MS. I'd be more than happy to help you with stuff then. ^_^ |
|
| Author: | Joost [ Sun Sep 02, 2007 10:23 pm ] |
| Post subject: | Re: Can't get a case to work right. |
You should uncomment that last End If. You have two ifstatements, and one EndIf. There is a sub in ES that handles Sadscript errors, but the actual logging of it is commented out. Furthermore, like the above people, I can suggest getting help at ES, most people here don't use scripting in their game/engine. /my bad, just saw the first If statement is commented out as well, consider this post worthless. |
|
| Author: | Egon [ Tue Sep 04, 2007 4:12 am ] |
| Post subject: | Re: Can't get a case to work right. |
Yeah, I know you guys don't support ES here. I was just hoping to get it working. Anyway, I'm pulling a mulligan, this never happened. |
|
| Author: | Rezeyu [ Tue Sep 04, 2007 4:14 am ] |
| Post subject: | Re: Can't get a case to work right. |
I'd help but, I've only opened up ES a handful of times; so I wouldn't really know what I'm talking about. Although since it's a string case, I'm assuming that sub from the script is called when a player sends chat text.. so I really dunno why it's not working. |
|
| Page 1 of 1 | All times are UTC |
| Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |
|