Another year is about to end... So we have to update these damn copyright information :P
[PHP-P10.git] / Uplink / P10_Channel.class.php
index 4fe3a205ae27552f402a1d6e735e675d4f66d983..0022b623cd2a5cc1dd2dfad1df84d160866d3226 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /******************************* PHP-P10 v2 *****************************
- * Copyright (C) 2011  Philipp Kreil (pk910)                            *
+ * Copyright (C) 2011-2012  Philipp Kreil (pk910)                       *
  *                                                                      *
  * This program is free software: you can redistribute it and/or modify *
  * it under the terms of the GNU General Public License as published by *
@@ -54,7 +54,8 @@ class P10_Channel {
        private $create_time;
        private $users = array();
        const USERPRIV_OPED  = 0x0001;
-       const USERPRIV_VOICE = 0x0002;
+       const USERPRIV_HALFOP = 0x0002;
+    const USERPRIV_VOICE = 0x0004;
        private $userPrivs = array();
        
        public function __construct($name) {
@@ -94,9 +95,9 @@ class P10_Channel {
                $user->addChannel($this);
        }
        
-       public function burstUser($user, $opped, $voiced) {
+       public function burstUser($user, $opped, $halfopped, $voiced) {
                $this->users[$user->getNumeric()] = $user;
-               $this->userPrivs[$user->getNumeric()] = ($opped ? self::USERPRIV_OPED : 0) | ($voiced ? self::USERPRIV_VOICE : 0);
+               $this->userPrivs[$user->getNumeric()] = ($opped ? self::USERPRIV_OPED : 0) | ($halfopped ? self::USERPRIV_HALFOP : 0) | ($voiced ? self::USERPRIV_VOICE : 0);
                $user->addChannel($this);
        }