Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames

USARBot.Item


00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
class Item extends Actor config(USARBot) abstract;

var string ItemName;
var string ItemType;
var name   ItemMount;

var USARConverter converter;
var vector myPosition;
var rotator myDirection;
var KVehicle Platform;

var config float Weight;

function SetName(String iName)
{
    ItemName = iName;
}

function string Set(String opcode, String args)
{
    return "Failed";
}

simulated function Init(String SName, Actor parent, vector position, rotator direction, KVehicle veh, name mount)
{
    Platform = veh;
    if (mount=='None')
        ItemMount = 'HARD';
    else
        ItemMount = mount;
    ItemName = SName;
    SetBase(parent);
    SetRelativeRotation(direction);
    myPosition = position;
    myDirection = direction;
    if(Platform == None) //Multi-View has a camera without any platform
        converter = None;
    else if (Platform.IsA('KRobot'))
        converter = KRobot(Platform).Converter;
    /*else if (Platform.IsA('USARCar'))
        converter = USARCar(Platform).Converter;
    else if (Platform.IsA('USARBc'))
        converter = USARBc(Platform).Converter;*/
    else
        converter = None;

    ConvertParam(converter);
}

simulated function ConvertParam(USARConverter converter)
{
}

function bool isType(String type)
{
    return (Caps(ItemType)==Caps(type));
}

function bool isName(String name)
{
    return (Caps(ItemName)==Caps(name));
}

defaultproperties
{
    ItemType="Item"
    DrawType=DT_StaticMesh
    DrawScale=0.1
    StaticMesh=StaticMesh'USARSim_VehicleParts_Meshes.Sensors.Sensor'
    bHardAttach=true
    RemoteRole=ROLE_None
    Weight=0.4
}

Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames
Class file time: Fr 12.1.2007 20:47:16.000 - Creation time: Mo 16.4.2007 11:20:49.000 - Created with UnCodeX