Jump to content

small help


WASSIm.

Recommended Posts

Posted

hi guys

i want if of 20 to 7 hour create object and if not. create marker

  
        if (h > 7)  and (h < 20) then 
        local marker = createObject(3877,tonumber(getElementData(groundweapon, "posX")), 
        tonumber(getElementData(groundweapon, "posY")), 
        tonumber(getElementData(groundweapon, "posZ"))-1) 
        setElementCollisionsEnabled(marker,false) 
        setElementAlpha(marker,0) 
        setElementInterior(marker, tonumber(getElementData(groundweapon, "interior"))) 
        setElementDimension(marker, tonumber(getElementData(groundweapon, "dimension"))) 
        setElementData(temp, "colshape.marker", marker) 
        else 
        local marker = createMarker(tonumber(getElementData(groundweapon, "posX")), 
        tonumber(getElementData(groundweapon, "posY")), 
        tonumber(getElementData(groundweapon, "posZ"))+0.05, 
        "corona", 0.5, weaponmarkercolors[slot][1],weaponmarkercolors[slot][2], weaponmarkercolors[slot][3], 80) 
        setElementInterior(marker, tonumber(getElementData(groundweapon, "interior"))) 
        setElementDimension(marker, tonumber(getElementData(groundweapon, "dimension"))) 
        setElementData(temp, "colshape.marker", marker) 
        end 
  

Posted
if (h > 7)  and (h < 20) then 

That'll only create the object if the hour is higher than 7, maybe you wanted to create the object if hour is equal or higher than 7?

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...