Lieber Besucher, herzlich willkommen bei: sourceserver.info. Falls dies Ihr erster Besuch auf dieser Seite ist, lesen Sie sich bitte die Hilfe durch. Dort wird Ihnen die Bedienung dieser Seite näher erläutert. Darüber hinaus sollten Sie sich registrieren, um alle Funktionen dieser Seite nutzen zu können. Benutzen Sie das Registrierungsformular, um sich zu registrieren oder informieren Sie sich ausführlich über den Registrierungsvorgang. Falls Sie sich bereits zu einem früheren Zeitpunkt registriert haben, können Sie sich hier anmelden.
Quellcode |
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 |
import es import random import os import gamethread import cPickle import threading import urllib2 import langlib ############################# # # # START OF CONFIG # # # ############################# # Pfad fuer die Sounds der Terrors # Path for the sounds of terrors resPfadT = 'res/gts-fun.de/T' # Pfad fuer die Sounds der Counters # Path for the sounds of counters resPfadCT = 'res/gts-fun.de/CT' # Unterbricht laufende Sounds, an = 1 , aus = 0 (funktioniert nicht perfekt) # Disrupt playing sounds, on = 1 , off = 0 (works not perfectly) resBreaker = 1 # Lautstaerkenregelung von 0.1 -1.0 # volume control from 0.1 - 1.0 resVolume = 1.0 # Wenn auf dem Server Gungame laeuft, ja = 1 , nein = 0 (funktioniert nur mit ES Gungame) # If GunGame runs on Server, yes = 1 , no = 0 (Works only with ES Gungame) resGunGame = 0 # spieler duerfen sound ein- und auschalten. # Allow players to enable and disable sounds resOnOff = 1 # Befehl zum ein- uns auschalten der Sounds # Command to enable and disable the sounds resOnOffcommand = '!res' # Alle x runden Werbung fuer resOnOffcommand. 0 = aus # All x round advertising for resOnOffcommand. 0 = aus resAdvtOnOffcommand = 10 # Team spezifische Sounds, an = 1 , aus = 0 # Team specific sounds, on = 1 , off = 0 resTeamS = 1 # Zufalls Sound bei unentschieden, an = 1 , aus = 0 # Random sound when a draw, on = 1 , off = 0 resDrawSound = 1 # Jeder Spieler hoert einen andern Sound, an = 1 , aus = 0 # Each player hears another sound, on = 1 , off = 0 resRandomSound = 1 # Spielt Sounds in fester Reihenfolge. Deaktiviert resRandomSound und aktiviert resTeamS # Playing sounds in a fixed sequence. ResRandomSound disabled and enabled resTeamS resOrderSound = 0 # Spielt bekommen den Soundnamen angezeigt # Shows the sound name resFileName = 1 # Updates checken, ja = 1 , nein = 0 # Update check, yes = 1 , no = 0 resUpdateCheck = 1 # Admins, die eine Info erhalten sollen wenn ein Update verfuegbar ist # Admins who are to receive a notification when an update is available resUpdateAdmins = 'STEAM_0:1:39818826' ############################# # # # END OF CONFIG # # # ############################# ######################################################################################### ### Do not change anything under this line unless you know exectly what you are doing ### ### Unter dieser Linie nichts veraendern ausser du weist was du da tust ### ######################################################################################### info = es.AddonInfo() info.name = "Round End Sounds" info.version = "2.03" info.author = "FreeZ" info.url = "http://myactive.eu" info.basename = "roundendsounds" info.description = "Round End Sounds for CSS" info.copyright = "2010 - 2120" translation_file = langlib.Strings(es.getAddonPath("res") + "/translation.ini") resSoundlist = {} resSoundlistT = {} resSoundlistCT = {} resSoundsoff = {} translationsini = {} picklePfad = 'cstrike/addons/eventscripts/res/soundsoff.data' current_version = float(info.version) def load(): global resGGWin global resSoundlistT global resSoundlistCT global lenT global lenCT global resRandomSound global resTeamS es.set(info.basename , info.version) es.makepublic(info.basename) try: unpickle() es.dbgmsg(0, '[RES] could load userdata') except: es.dbgmsg(0, '[RES] could not load userdata') resGGWin = 0 resSoundlistT = os.listdir('%s/cstrike/sound/%s/' % (os.getcwd(),resPfadT)) resSoundlistCT = os.listdir('%s/cstrike/sound/%s/' % (os.getcwd(),resPfadCT)) if resOrderSound == 1: lenT = len(resSoundlistT) lenCT = len(resSoundlistCT) resRandomSound = 0 resTeamS = 1 def es_map_start(ev): global resGGWin global counterT global counterCT global roundcounter counterT = -1 counterCT = -1 download() if resGunGame == 1: resGGWin = 0 roundcounter = 0 def gg_win(ev): global resGGWin if resGunGame == 1: resGGWin = 1 def round_end(ev): pickle() if resBreaker == 0: gamethread.delayed(.2, playpreparation, (ev["winner"])) elif resBreaker == 1: gamethread.delayed(.1, es.cexec_all, ('play 0')) gamethread.delayed(.2, playpreparation, (ev["winner"])) def round_start(ev): global lenT global lenCT global winflag global counterT global counterCT global roundcounter if resOrderSound == 1: if winflag == 2: if counterT < lenT-1: counterT = counterT + 1 else: counterT = 0 elif winflag == 3: if counterCT < lenCT-1: counterCT = counterCT + 1 else: counterCT = 0 if resAdvtOnOffcommand-1 == roundcounter: translationsini['onoffcommand'] = str(resOnOffcommand) es.msg('#multi', translation_file('res onoff command', translationsini)) roundcounter = 0 else: roundcounter = roundcounter + 1 def playpreparation(winner): global winflag global counterT global counterCT if resGGWin == 0: if resTeamS == 0: resZahl = random.randint(1, 10) if resZahl <= 5: soundplayer(resPfadT,resSoundlistT, winner) elif resZahl >=6: soundplayer(resPfadCT,resSoundlistCT, winner) elif resTeamS == 1: if winner == "2": winflag = 2 if resOrderSound == 1: soundplayer(resPfadT,resSoundlistT[counterT], winner) else: soundplayer(resPfadT,resSoundlistT, winner) elif winner == "3": winflag = 3 if resOrderSound == 1: soundplayer(resPfadCT,resSoundlistCT[counterCT], winner) else: soundplayer(resPfadCT,resSoundlistCT, winner) elif winner == "1": if resDrawSound == 1: resZahl = random.randint(1, 10) if resZahl <= 5: soundplayer(resPfadT,resSoundlistT, winner) elif resZahl >=6: soundplayer(resPfadCT,resSoundlistCT, winner) def soundplayer(resPfad,resSoundlist, winner): sound = random.choice(resSoundlist) #es.msg("#multi", '#green DEBUG %s' % (resSoundlist)) for player in es.getUseridList(): if es.getplayersteamid(player) not in resSoundsoff: if resRandomSound == 1: randomchoice = random.choice(resSoundlist) es.playsound(player, resPfad + "/" + randomchoice, resVolume) if resFileName == 1: translationsini['filename'] = str(randomchoice).replace(".mp3","").replace(".wav","") es.tell(player, '#multi',translation_file('res file name', translationsini)) else: if resOrderSound == 1: if winner == "1": randomchoice = random.choice(resSoundlist) es.playsound(player, resPfad + "/" + randomchoice, resVolume) if resFileName == 1: translationsini['filename'] = str(randomchoice).replace(".mp3","").replace(".wav","") es.tell(player, '#multi',translation_file('res file name', translationsini)) else: es.playsound(player, resPfad + "/" + resSoundlist, resVolume) if resFileName == 1: translationsini['filename'] = str(randomchoice).replace(".mp3","").replace(".wav","") es.tell(player, '#multi',translation_file('res file name', translationsini)) else: es.playsound(player, resPfad + "/" + sound, resVolume) if resFileName == 1: translationsini['filename'] = str(randomchoice).replace(".mp3","").replace(".wav","") es.tell(player, '#multi',translation_file('res file name', translationsini)) def player_say(ev): if resOnOff == 1: if ev['text'] == resOnOffcommand: if ev['es_steamid'] not in resSoundsoff: resSteamid = ev['es_steamid'] resSoundsoff[resSteamid] = 1 es.tell(ev['userid'], '#multi', translation_file('res off message', translationsini)) else: del resSoundsoff[ev['es_steamid']] es.tell(ev['userid'], '#multi', translation_file('res on message', translationsini)) def download(): for i in range(0, len(resSoundlistT)): if resSoundlistT[i].endswith('wav') or resSoundlistT[i].endswith('mp3'): es.stringtable('downloadables', 'sound/%s/%s' %(resPfadT, resSoundlistT[i])) for i in range(0, len(resSoundlistCT)): if resSoundlistCT[i].endswith('wav') or resSoundlistCT[i].endswith('mp3'): es.stringtable('downloadables', 'sound/%s/%s' %(resPfadCT, resSoundlistCT[i])) def pickle(): '''save data''' f = file(picklePfad, 'w') cPickle.dump(resSoundsoff, f) f.close() def unpickle(): global gjJoins '''get data back''' f = file(picklePfad) resSoundsoff = cPickle.load(f) f.close() def player_activate(ev): global new_version updatecheck().start() steamid = ev["es_steamid"] if resUpdateCheck == 1: if steamid in resUpdateAdmins: if new_version != current_version: translationsini['current_version'] = str(current_version) translationsini['new_version'] = str(new_version) es.tell(ev['userid'], '#multi', '#lightgreen-----------------------------------------') es.tell(ev['userid'], '#multi', translation_file('update message', translationsini)) es.tell(ev['userid'], '#multi', translation_file('download update message', translationsini)) es.tell(ev['userid'], '#multi', '#lightgreen-----------------------------------------') es.tell(ev['userid'], '#multi', translation_file('update message', translationsini)) es.tell(ev['userid'], '#multi', translation_file('download update message', translationsini)) es.tell(ev['userid'], '#multi', '#lightgreen-----------------------------------------') class updatecheck(threading.Thread): def run(self): global new_version version_data = urllib2.urlopen("http://gts-fun.de/addons_ev/res/res.php").read() new_version = float(version_data) |
Quellcode |
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
// server name hostname "[myActive] GunGame Turbo Bunker | DeathMatch | ShowDmg | Soundlist | Wurfmesser | Rank | Stamm" sv_tags "zombie,zr,fun,ZR,dream-net,jail,rat,new,map,tv,tower,mg,fun,awp,poolparty,pool,party,surf,xdr4am,deathrun,death,dl,run,only,bhop,knasthaus,jb,fastdl,ger,stamm,hosties,sm_hosties,fps,dl,1000,Aim,Aming,FPS,Pool,Jail,Knast,Minigame,Sport,alltalk,bunnyhop,game,gg,gun,gungame,aim,AoG" // rcon passsword //sv_password "test" rcon_password "Das wüsstest du gerne <3" // Advanced RCON sv_rcon_banpenalty 60 sv_rcon_maxfailures 10 sv_rcon_minfailures 5 sv_rcon_minfailuretime 30 // server cvars mp_friendlyfire 0 mp_footsteps 1 mp_autoteambalance 1 mp_autokick 0 mp_flashlight 1 mp_tkpunish 1 mp_forcecamera 0 sv_alltalk 0 sv_pausable 0 sv_cheats 0 sv_consistency 1 sv_allowupload 1 sv_allowdownload 1 sv_maxspeed 320 mp_limitteams 0 mp_hostagepenalty 5 sv_voiceenable 1 mp_allowspectators 1 mp_timelimit 25 mp_chattime 10 sv_timeout 65 sv_downloadurl "http://istjawohlegal.de/fastdl/cstrike/" cl_downloadfilter "all" // round specific cvars mp_freezetime 3 mp_roundtime 10 mp_startmoney 800 mp_c4timer 45 mp_fraglimit 0 mp_maxrounds 0 mp_winlimit 0 mp_playerid 0 mp_spawnprotectiontime 5 // server logging log off sv_logbans 0 sv_logecho 1 sv_logfile 1 sv_log_onefile 0 // operation sv_lan 0 sv_region -1 // execute ban files exec banned_user.cfg exec banned_ip.cfg exec autoexec.cfg |
Quellcode |
|
1 |
es_load res |
Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von »fluxX« (15. März 2013, 07:39)
Dieser Beitrag wurde bereits 2 mal editiert, zuletzt von »RyukThaShinigam« (15. März 2013, 13:51)
Andere hinzugefügt und manche gelassen wie sie ist. Aber nix von beiden funktioniert o:hmm dann ist das sehr komisch, weil normalerweise funktioniert das plugin ohne probleme. Hast du eigne Musik hinzugefügt oder die Musik so gelassen wie sie dabei war?
Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von »fluxX« (15. März 2013, 16:02)