Bioluminescence

Nebulazer

Valued Member!
One of the new "classes" in InvasionZ is called a 'Glower'. For its name to stand true I need its skin to glow. Could someone help me out with a line of code that should make light come off of the object? I am pretty certain its possible because you can control how much light comes off of light sources and such, but this is beyond me atm.
 
Why you´re not adding a chemstick to it ? Guess thats a first step in the right direction.

This is a pretty good Idea if i cant get what i am thinking to work. I would have to figure out how to make the chem light invisible though.
Code:
 if((_awayx>1 or _awayx<-1)or(_awayy>1 or _awayy<-1))then{
                _location set [1, (_x select 1) + ((0.6)*sin(_x select 3))];
                _location set [2,_location select 2 - 0.2];
                _location=[_location select 0, _location select 1, _location select 2];
                _lp = "#lightpoint" createVehicle _location;
                _lp setLightColor [1, 0.88, 0.73];
                _lp setLightBrightness 0.04;
                _lp setLightAmbient [1, 0.88, 0.73];
                _lp setVectorUp [0,0,-1];
                player reveal _lp;
                //hint format ["LAMP NOT FOUND:%1 | %2",_x,time];
                sleep 0.2;
                }else{
                //hint format["LAMP ALREADY FOUND | Var:%1",_objLightPoint getVariable "axeLit"];
                    if(_objLightPoint getVariable ["axeLit",0]<1)then{
                    _objLightPoint setLightColor [1, 0.88, 0.73];
                    _objLightPoint setLightBrightness 0.04;
                    _objLightPoint setLightAmbient [1, 0.88, 0.73];
                    _objLightPoint setVectorUp [0,0,-1];
                    };
                sleep 0.2;
                };
I found that in a post by Axeman, but I am not certain how to convert it to a player or how exactly it should be used like that.
 
on one of my servers, you could group with other players, spin wheel option to tag the player as friendly>player accepts>you both would get "Sign_sphere10cm_EP1" attached to your wrists (was a lil light orb), so you could easily identifly people in your group. i played with the code and attached giant UN Flags to the group, i attached a huge red arrow that would point down over the heads of the group, i attached fire barrels.. basically you can attach whatever you wanted.. but heres the link to the codes. fiddle around with it and im sure youll get close to the result you want.

Files

Code:
// create tags
{
  if (isPlayer _x) then {
    _rcharID = _x getVariable ["characterID", "0"];
    _rfriendlies = _x getVariable ["friendlies", []];
    _rfriendlyTo = _x getVariable ["friendlyTo", []];
    if ((_rcharID in _friendlies) and (_charID in _rfriendlies)) then {
      if (!(_charID in _rfriendlyTo)) then {
        _position = [0,0,0];
        _tag = "Sign_sphere10cm_EP1" createVehicleLocal _position;
        _tag attachTo [_x,[0,0,0],"lwrist"];
        _tag setVariable ["belongsTo", _rcharID];
        _rfriendlyTo set [count _rfriendlyTo, _charID];
        _x setVariable ["friendlyTo", _rfriendlyTo, true];
      _tagList set [count _tagList, [_x, _tag]];
        player setVariable ["tagList", _tagList];
      titleText [format["You and %1 are now tagged as friendlies.", (name _x)], "PLAIN DOWN"];
      };
    };
};

OC -
R4Z0R49
 
on one of my servers, you could group with other players, spin wheel option to tag the player as friendly>player accepts>you both would get "Sign_sphere10cm_EP1" attached to your wrists (was a lil light orb), so you could easily identifly people in your group. i played with the code and attached giant UN Flags to the group, i attached a huge red arrow that would point down over the heads of the group, i attached fire barrels.. basically you can attach whatever you wanted.. but heres the link to the codes. fiddle around with it and im sure youll get close to the result you want.

Files

Code:
// create tags
{
  if (isPlayer _x) then {
    _rcharID = _x getVariable ["characterID", "0"];
    _rfriendlies = _x getVariable ["friendlies", []];
    _rfriendlyTo = _x getVariable ["friendlyTo", []];
    if ((_rcharID in _friendlies) and (_charID in _rfriendlies)) then {
      if (!(_charID in _rfriendlyTo)) then {
        _position = [0,0,0];
        _tag = "Sign_sphere10cm_EP1" createVehicleLocal _position;
        _tag attachTo [_x,[0,0,0],"lwrist"];
        _tag setVariable ["belongsTo", _rcharID];
        _rfriendlyTo set [count _rfriendlyTo, _charID];
        _x setVariable ["friendlyTo", _rfriendlyTo, true];
      _tagList set [count _tagList, [_x, _tag]];
        player setVariable ["tagList", _tagList];
      titleText [format["You and %1 are now tagged as friendlies.", (name _x)], "PLAIN DOWN"];
      };
    };
};

OC -
R4Z0R49

This is something I am going to mess around with for sure, thank you. maybe a way to attach a Chemlight (HandChemGreen) hidden inside the body. Will it run out eventually like that? Or is there a way to make it last forever? If you would like to work on this with me, we can talk more in teamspeak. Send me a message if you are interested.
 
hidden? no. if it was hidden, how would you see it? :p lol. ummm theres way more code then that snippet there. i guess you would just modify the check code that checks to see if player X = whatever. and dont have it do the check. if i could see the bit of code you have for the creature you made that you want to glow, id have a better idea of what to tweak.
 
hidden? no. if it was hidden, how would you see it? :p lol. ummm theres way more code then that snippet there. i guess you would just modify the check code that checks to see if player X = whatever. and dont have it do the check. if i could see the bit of code you have for the creature you made that you want to glow, id have a better idea of what to tweak.
In arma, lights pass through things like they are not there. If its inside of a body you should see the light but not the stick itself. Have you tried this? I guarantee it will work if you can actually place the object there.
 
if you can send me the class-file for the Glower critter it would help a lot. im no coder, but after running 3 servers for 6 months or so, ive figured out how to Frankenstein different codes to do different things. attaching stuff to objects was the last things i actually touched base on.
 
i guess id have to look at the coding for light sources. like streetlights, and see how it attaches it.

Would you want to help add this to the InvasionZ level script? So that when you turn into a Glower, you glow. We could use help finishing the level script up also. Message me for teamspeak info if you are interested.
 
I'm using this in a script I'm working on at the moment no idea how you would activate it in your script because I'm using the mission.sqm but here is the code anyway
Code:
 expActiv="light = ""#lightpoint"" createVehicleLocal position toto; light setLightBrightness 0.05; light setLightAmbient[1.0, 1.0, 1.0]; light setLightColor[1.0, 0.5, 0.5]; light lightAttachObject [toto, [0,0,1]]; ";
 
I'm using this in a script I'm working on at the moment no idea how you would activate it in your script because I'm using the mission.sqm but here is the code anyway
Code:
 expActiv="light = ""#lightpoint"" createVehicleLocal position toto; light setLightBrightness 0.05; light setLightAmbient[1.0, 1.0, 1.0]; light setLightColor[1.0, 0.5, 0.5]; light lightAttachObject [toto, [0,0,1]]; ";

ah yes! i think this is what I was looking for. This adds light to any object, correct? Even something without lightbulbs? Will the whole object glow or just a certain point? Thank you
 
The whole object and will make the entire thing glow. Your welcome :)

I'll get you to give me a hand with something small and simple later today if that's okay, just some stuff about _this, can't seem to get my head around it.
 
I will certainly help you if I am able to. If you would like to talk in a teamspeak, message me and ill give you the IP.
 
Ok back in july, i had figured out how to tag a player as friendly, and when they were tagged it would add a red orb on their wrist.
now i have a Epoch server, and it has the tag friendly option already implemented. but i want to add the red orb to each person tagged as friendly.. where would i put it?

Code:
// create tags
{
  if (isPlayer _x) then {
    _rcharID = _x getVariable ["characterID", "0"];
    _rfriendlies = _x getVariable ["friendlies", []];
    _rfriendlyTo = _x getVariable ["friendlyTo", []];
    if ((_rcharID in _friendlies) and (_charID in _rfriendlies)) then {
      if (!(_charID in _rfriendlyTo)) then {
        _position = [0,0,0];
        _tag = "Sign_sphere10cm_EP1" createVehicleLocal _position;
        _tag attachTo [_x,[0,0,0],"lwrist"];
        _tag setVariable ["belongsTo", _rcharID];
        _rfriendlyTo set [count _rfriendlyTo, _charID];
        _x setVariable ["friendlyTo", _rfriendlyTo, true];
      _tagList set [count _tagList, [_x, _tag]];
        player setVariable ["tagList", _tagList];
      titleText [format["You and %1 are now tagged as friendlies.", (name _x)], "PLAIN DOWN"];
      };
    };
};
 
They had this built into Epoch before, but removed it as it was glitchy whether or not it would show up, and was not visible enough to make a visual difference at an engagement distance.

I cant find the code they used then to do it or I'd link you to it.
 
Ya and thats exactly what i thought too.. that little orb is so small from a distance. so i put a big downward facing arrow that was a opaque reddish color. there was no missing this thing, it was about as big as the survivor.
 
Back
Top