Eclipse
January 05, 2009, 10:04:40 PM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News:
 
   Home   Chat Help Rules Arcade Search Calendar Gallery Login Register  
 
 
 
Recent Topics +-
I need a little help by waffletamer
Today at 10:03:40 PM

Actual Map for the continents by MrMiguu™
Today at 10:00:23 PM

World of Hyrule - Official Topic by MrMiguu™
Today at 09:58:39 PM

Lostica [Project Revamp] by MrMiguu™
Today at 09:56:40 PM

Disparity Recruiting by Peter
Today at 09:49:31 PM

Okay Questions (very noob person here) by The Roujo
Today at 09:48:45 PM

fun with photoshop by MrMiguu™
Today at 09:48:19 PM

stackable items? by MrMiguu™
Today at 09:45:06 PM

scripts? by MrMiguu™
Today at 09:44:14 PM

Party system : is it possible? by MrMiguu™
Today at 09:43:48 PM

Members Online +-
10 Guests, 20 Users
slym,
HawkStorm95,
shakadaran,
ralir,
Amperglyph,
waffletamer,
Gwendalin,
Sablefalcon,
dg1423,
dragonlord52,
Sk3wer,
‪‫‬‭‮‪‫Kusy,
MrMiguu™,
Kreator,
Ambard,
‪‫‬‭‮‪‫‬‭The Admiral,
Baron,
Haruhito,
Peter,
The Roujo
Pages: [1]
  Print  
Author Topic: Block Player Script  (Read 2074 times)
0 Members and 1 Guest are viewing this topic.
Steve
Active Member
***
Offline Offline

Posts: 171


View Profile WWW Email
« on: February 04, 2006, 08:50:25 AM »

I never knew who made this script but whoever did all the credit goes to you.I will show you what to add at the bottom of you main.txt.An them 2 examples.

Add this to the bottom of you main.txt
Code: [Select]

Sub BlockPlayer(index)
   playerdir = GetPlayerDir(index)
   Select Case playerdir
         Case 0
           Call PlayerWarp(index, GetPlayerMap(index), GetPlayerX(index), GetPlayerY(index)+1)
         Case 1
           Call PlayerWarp(index, GetPlayerMap(index), GetPlayerX(index), GetPlayerY(index)-1)
       Case 2
           Call PlayerWarp(index, GetPlayerMap(index), GetPlayerX(index)+1, GetPlayerY(index))
         Case 3
           Call PlayerWarp(index, GetPlayerMap(index), GetPlayerX(index)-1, GetPlayerY(index))
   End Select
End Sub

This will make it all work now i will give to examples.
Code: [Select]

Case 0
If getplayerlevel(indes) < !LEVEL! Then
     Call blockPlayer(index)
End if

Or you couls do it in a sub like so
Code: [Select]

Sub NeedToBeBlock()
If getplayerlevel(indes) < !LEVEL! Then
     Call blockPlayer(index)
End if

And here is the final
Code: [Select]

Case "/Level"
If getplayerlevel(indes) < !LEVEL! Then
     Call blockPlayer(index)
End if
Exit Sub

Here is the newest command you can use.
Code: [Select]

Call BlockPlayer(index)
Unknown_raven
Newb
*
Offline Offline

Posts: 5


View Profile Email
« Reply #1 on: February 06, 2006, 10:50:27 AM »

*EDIT*Anyhow it was made by me.
konceptz
Active Member
***
Offline Offline

Posts: 173


View Profile Email
« Reply #2 on: February 07, 2006, 05:40:43 PM »

this script seems to be completely useless no offence but i really don't see use in it.. :(
Marsh
Demi God

Offline Offline

Posts: 7,280


Comfort the disturbed. Disturb the comfortable.


View Profile WWW Email
User is on moderator watch listWatched
« Reply #3 on: February 07, 2006, 05:46:21 PM »

Quote from: konceptz
this script seems to be completely useless no offence but i really don't see use in it.. :(


Its very usefull. If you only want high level charectors to be allowed in.
IceCream Tuesday
Advanced Eclipser
*****
Offline Offline

Posts: 1,524


<3 you


View Profile Email
« Reply #4 on: February 07, 2006, 05:58:39 PM »

yeah this is a good script and you can always alter it so it can block anything
Spike
Veteran
Advanced Eclipser
*
Offline Offline

Posts: 1,667



View Profile Email
« Reply #5 on: February 08, 2006, 12:47:16 PM »

very good *claps*
konceptz
Active Member
***
Offline Offline

Posts: 173


View Profile Email
« Reply #6 on: February 08, 2006, 02:55:52 PM »

ok, OK i get it it's a good script...
Steve
Active Member
***
Offline Offline

Posts: 171


View Profile WWW Email
« Reply #7 on: February 20, 2006, 08:44:12 AM »

Sorry about that Unknown_raven i will add it and you can use this script for may things as so:
Code: [Select]

Sub AdminGuild()
If GetPlayerGuild(index) = "Admin Guild" Then
Call PlayerMsg(index, "Welcome to the guild", 3)
Else
Call PlayerMsg(index, "You are not welcomed you are no admin", 3)
Call BlockPlayer(index)
End If
End Sub

There are so many ways to use this script.
Baron
Lord Of Spleens
Administrator
Teh Uberleet
*
Online Online

Posts: 2,739


Genesis CoCreator - Eclipse Evo Developer


View Profile WWW Email
« Reply #8 on: February 20, 2006, 08:50:03 AM »

This is an incredibly useful piece of script. anyone who cant see the value here doesnt really understand what they are looking at.
mikis
Newb
*
Offline Offline

Posts: 15


View Profile Email
« Reply #9 on: February 23, 2006, 11:31:14 AM »

this script is wery useful  :D
IceCream Tuesday
Advanced Eclipser
*****
Offline Offline

Posts: 1,524


<3 you


View Profile Email
« Reply #10 on: February 23, 2006, 12:15:33 PM »

ALRIGHT ALRIGHT we all know its usefull
tommy
Newb
*
Offline Offline

Posts: 12


View Profile Email
« Reply #11 on: March 19, 2006, 04:42:58 PM »

2 b honest love the script man i think its very usefull
n0madic0debc
Active Member
***
Offline Offline

Posts: 415


View Profile Email
« Reply #12 on: March 20, 2006, 12:29:50 PM »

This script i dont see the point of it.....
l0lz!
I <3 Photoshop
Veteran
Advanced Eclipser
*
Offline Offline

Posts: 1,149



View Profile WWW Email
« Reply #13 on: September 24, 2006, 08:12:11 AM »

yea but it onlly blocks one level right? what about one lvl and up? for example... block level 70  but only level 70's cant get through if your lower than it then u can go through so it dosent matter what level you are you can pass through exept lvl 70? couldnt you put lvl 50 to level 90?
Cantifla@School
Guest


Email
« Reply #14 on: October 11, 2006, 03:48:51 AM »

Case "/Level"
If getplayerlevel(index) <= !LEVEL! Then
     Call blockPlayer(index)
End if
Exit Sub

there, adding a "<=" (Less than equal to) in there will only block players that are less than equal to !LEVEL!(example: 70)
Cantinfla@School
Guest


Email
« Reply #15 on: October 11, 2006, 04:12:30 AM »

Above post edit:

If you want to block a certain level range(ex: 1 to 20)
Do this:

Case "/Level"
If getplayerlevel(index) <= 1 Then
If getplayerlevel(index) >= 20 Then
     Call blockPlayer(index)
End If
End If
Exit Sub

This means players over level 20 may pass, but not below.
Bobosk
Veteran
Advanced Eclipser
*
Offline Offline

Posts: 1,110


View Profile Email
« Reply #16 on: October 11, 2006, 09:01:37 AM »

There's a small problem with that Cantinfla, the case needs to be Case # not Case "/level".. Case "/level" is for saying it... (like "/help" and such)
Cantinfla
Mid Scripter
Member
**
Offline Offline

Posts: 40



View Profile Email
« Reply #17 on: October 11, 2006, 08:33:47 PM »

I just copyed over what he wrote, my bad if i didnt noticed that, was posting fast. =p
.:Mike:.
Advanced Member
****
Offline Offline

Posts: 643


mariah :) my one and only


View Profile Email
« Reply #18 on: October 17, 2007, 12:40:30 PM »

I have a question...In my game theres a training room for people under level 10 so i put

Case 0
If getplayerlevel(indes) <= 10 Then
     Call blockPlayer(index)
End if

How do i acually block everyone over level 10 from getting in?
Pages: [1]
  Print  
 
 

Powered by EzPortal
Powered by MySQL Powered by PHP Powered by SMF 2.0 Beta 4 | SMF © 2006–2008, Simple Machines LLC | Sitemap Valid XHTML 1.0! Valid CSS!
Page created in 0.593 seconds with 32 queries.