blob: 90d886e7b561eb71fa49cabda949750859b4b3a4 [file] [log] [blame]
MG Mud User88f12472016-06-24 23:31:02 +02001// MorgenGrauen MUDlib
2//
3// virtual_compiler.c -- Virtueller Compiler fuer die Todesraeume
4//
5// $Id.$
6
7
8#pragma strong_types
9
10inherit "/std/virtual/v_compiler";
11
12#include <defines.h>
13#include <v_compiler.h>
14
15int NoParaObjects() {return 1;}
16
17void create()
18{
19 if (IS_CLONE(this_object())) return;
20 ::create();
21 SetProp(P_STD_OBJECT, "/room/death/death_room_vc");
22 seteuid(getuid());
23 return;
24}
25
26string Validate(string file) {
27 string base, room, who;
28
29 file = ::Validate(file);
30 if(sscanf(file, "death_room_%s",who)!=1 ||
31 ((who[0..3]!="gast") &&
32 (!"/secure/master"->get_userinfo(who)))) return 0;
33 return file;
34}
35
36mixed CustomizeObject()
37{
38 string base,room,who,file,fun;
39
40 if(!(file = ::CustomizeObject()) ||
41 !Validate(file)) return 0;
42 return file;
43}
44