The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Events and Regions?
Author Message
Valios
Super Moderator
****

Posts: 390
Likes Given: 0
Likes Received: 12 in 9 posts
Joined: Mar 2010
Reputation: 6

Sphere Suite 2013

Post: #8
RE: Events and Regions?
There you go:

Code:
[comment eventguide]
Go to your sphere.ini, under the "NPC/Item/Player Management" look for this line of code:

// Events related to all regions
// EventsRegion=your_event

Replace the second line to this one:

EventsRegion=r_pre_event

[defname eventplaces]
eventplace_1 Britain

[function eventstatus] // --- function to enable/disable your event
    if !(<tag0.currentevent>)
          tag0.currentevent = 1
          sysmessage Current event status: ON
  else
          tag0.currentevent =
          tag0.regiontoleave =
          sysmessage Current event status: OFF

[function regionenter]
tag0.regiontoleave = 1

[function regionleave]
tag0.regiontoleave =

[regiontype r_pre_event]

on=@enter
   if (<eval <src.tag0.currentevent>> == 1)
     if !(strcmp(<region.name>, <def.eventplace_1>))        
          src.regionenter
  endif
endif

on=@exit
   if (<eval <src.tag0.currentevent>> == 1)
     if (<eval <src.tag0.regiontoleave>> == 1)
          src.say Hey Reflex, I just left Britain!
          src.regionleave
  endif
endif
05-04-2012 05:57 PM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Messages In This Thread
Events and Regions? - Reflex - 05-04-2012, 11:44 AM
RE: Events and Regions? - Valios - 05-04-2012, 12:49 PM
RE: Events and Regions? - Reflex - 05-04-2012, 12:51 PM
RE: Events and Regions? - Valios - 05-04-2012, 12:56 PM
RE: Events and Regions? - Reflex - 05-04-2012, 01:47 PM
RE: Events and Regions? - Valios - 05-04-2012, 02:39 PM
RE: Events and Regions? - Reflex - 05-04-2012, 03:11 PM
RE: Events and Regions? - Valios - 05-04-2012 05:57 PM
RE: Events and Regions? - Reflex - 05-04-2012, 07:15 PM

Forum Jump:


User(s) browsing this thread: 3 Guest(s)