Jump to content

Search the Community

Showing results for tags 'if'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • People Forum
    • Your Avatar
    • Make Friends
    • Lifestyles and Relationships
    • Role Play
    • General Discussion Forum
    • Forums Feedback
    • Missed Connections
    • Second Life Education and Nonprofits
  • Places and Events Forum
    • Favorite Destinations
    • Upcoming Events and Activities
    • Games in Second Life
  • Official Contests, Events & Challenges
    • Challenges
    • Contests
  • Creation Forum
    • Fashion
    • Art, Music and Photography
    • Animation Forum
    • Bakes on Mesh
    • Environmental Enhancement Project
    • Machinima Forum
    • Building and Texturing Forum
    • Mesh
    • LSL Scripting
    • LSL Library
    • Experience Tools Forum
  • Technology Forum
    • Second Life Server
    • Second Life Viewer
    • Second Life Web
    • General Second Life Tech Discussion
    • Mobile
  • Commerce Forum
    • Merchants
    • Inworld Employment
    • Wanted
  • Land Forum
    • General Discussion
    • Mainland
    • Linden Homes
    • Regions for Sale: Full Private Island
    • Region for Rent: Full Private Island
    • Regions for Sale: Homesteads
    • Region Rentals: Homestead
    • Parcels for Sale: Mainland
    • Parcels for Rent: Mainland
    • Wanted: Full Private Island
    • Wanted: Homesteads
    • Wanted: Mainland
  • International Forum
    • Deutsches Forum
    • Foro en español
    • Forum in italiano
    • Forum français
    • 日本語フォーラム
    • 한국어 포럼
    • Fórum em português
    • Forum polskie
    • المنتدى العربي
    • Türkçe Forum
    • Форум по-русски
  • Adult Content Forum
    • Highlight Upcoming Events
    • General Discussion
    • General Announcements
  • Answers
    • Abuse and Griefing
    • Account
    • Avatar
    • Creation
    • Inventory
    • Getting Started
    • Controls
    • Land
    • Linden Dollars (L$)
    • Shopping
    • Technical
    • Viewers
    • Everything Else
    • International Answers

Blogs

  • Commerce
  • Featured News
  • Inworld
  • Tools and Technology
  • Tips and Tricks
  • Land
  • Community News

Categories

  • English
  • Deutsch
  • Français
  • Español
  • Português
  • 日本語
  • Italiano
  • Pусский
  • Türkçe

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


About Me


Member Title

Found 3 results

  1. Dear All, I have been in SL quite a few years, but my scripting skills are still quite raw. I'm after some tips please to reduce my scripting down to less lines, as I am sure there must be a better way and I just can't understand on the wiki as they don't always explain all the possible configurations. I want to check the value of a time is between certain minutes (i.e. between 21and 30, between 31 and 40, between 41 and 50 or above 50) so that my "speaking clock" will read out "20","30","40" or "50" before it reads the minutes (i.e. "50" "1" for 51 minutes. Could anybody kindly help me in getting the syntax right so that it can check all of the above in one "IF" instead of having to do IF > ELSE in the same way I have? I'm basically hoping to say something like if (Minute>=21 && Minute<30) or (Minute>=31 && Minute<40) or (Minute>=41 && Minute<50) or (Minute>50) For your reference "Minute" is the variable taken from the time and represents the minutes in the hour. unimin = the unit measurement of the minutes, decmin = the tens measurement of the minutes (i.e. if the time is 15:34 then the decmin would equal "3" and the unimin would equal "4") a snippet of my huge code below - Thank you so much in advance!! if (Minute>=21 && Minute<30) { if (unimin==1) { llPlaySound("1",1.0); } else if (unimin==2) { llPlaySound("2",1.0); } else if (unimin==3) { llPlaySound("3",1.0); } else if (unimin==4) { llPlaySound("4",1.0); } else if (unimin==5) { llPlaySound("5",1.0); } else if (unimin==6) { llPlaySound("6",1.0); } else if (unimin==7) { llPlaySound("7",1.0); } else if (unimin==8) { llPlaySound("8",1.0); } else if (unimin==9) { llPlaySound("9",1.0); } } else if (Minute>=31 && Minute<40) { if (unimin==1) { llPlaySound("1",1.0); } else if (unimin==2) { llPlaySound("2",1.0); } else if (unimin==3) { llPlaySound("3",1.0); } else if (unimin==4) { llPlaySound("4",1.0); } else if (unimin==5) { llPlaySound("5",1.0); } else if (unimin==6) { llPlaySound("6",1.0); } else if (unimin==7) { llPlaySound("7",1.0); } else if (unimin==8) { llPlaySound("8",1.0); } else if (unimin==9) { llPlaySound("9",1.0); } } else if (Minute>=41 && Minute<50) { if (unimin==1) { llPlaySound("1",1.0); } else if (unimin==2) { llPlaySound("2",1.0); } else if (unimin==3) { llPlaySound("3",1.0); } else if (unimin==4) { llPlaySound("4",1.0); } else if (unimin==5) { llPlaySound("5",1.0); } else if (unimin==6) { llPlaySound("6",1.0); } else if (unimin==7) { llPlaySound("7",1.0); } else if (unimin==8) { llPlaySound("8",1.0); } else if (unimin==9) { llPlaySound("9",1.0); } } else if (Minute>50) { if (unimin==1) { llPlaySound("1",1.0); } else if (unimin==2) { llPlaySound("2",1.0); } else if (unimin==3) { llPlaySound("3",1.0); } else if (unimin==4) { llPlaySound("4",1.0); } else if (unimin==5) { llPlaySound("5",1.0); } else if (unimin==6) { llPlaySound("6",1.0); } else if (unimin==7) { llPlaySound("7",1.0); } else if (unimin==8) { llPlaySound("8",1.0); } else if (unimin==9) { llPlaySound("9",1.0); } } else if (Minute<10) { if (unimin==1) { llPlaySound("1",1.0); } else if (unimin==2) { llPlaySound("2",1.0); } else if (unimin==3) { llPlaySound("3",1.0); } else if (unimin==4) { llPlaySound("4",1.0); } else if (unimin==5) { llPlaySound("5",1.0); } else if (unimin==6) { llPlaySound("6",1.0); } else if (unimin==7) { llPlaySound("7",1.0); } else if (unimin==8) { llPlaySound("8",1.0); } else if (unimin==9) { llPlaySound("9",1.0); } }
  2. I'm working on a script but seem to be running into issues when it comes to having multiple requirements without having a specific order to which they are completed or confirmed as met to getting the script to work. For example, I am trying to design a breakable window, but I don't want anything under "x" amount of velocity to be allowed to damage the hit points. (this is only part of the script) collision(integer num) { if(vel < llVecMag(llDetectedVel(0)) && hp > 0) { llSetTexture("Broken",ALL_SIDES); } } If any of you can help I would greatly appreciate it, if you need more to help I'll be happy to give it and if you see that I'm doing anything wrong PLEASE let me know.. I'm getting frustrated with it.
  3. Hi everyone! I just started learning how to script in LSL and I've got a little script now by using the web and the wiki. However, there's a tiny thing that I can't find: I want to set a float variable (let's say its called "cat" from 0.0 to 1.0 by using an "if" command). so in my noobbrain it would look like: if(channel == 0) { cat = 1) } However, this doesn't work. How would I make this work properly? Thank you very much for your time!
×
×
  • Create New...