• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Integer Help

Status
Not open for further replies.
Level 3
Joined
Jul 28, 2006
Messages
40
I am having a hard time with integers -.-
They give me a headache.Can someone post some helping hints?Oh yeah.I tryed to make,for example,a info sistem on my map.But it didn't work and I know I did something right but I don't know what it is.I want it to show a random message from 20 to 20 seconds of the game.[/code]
 
Level 4
Joined
Oct 23, 2006
Messages
65
Paul47 said:
I am having a hard time with integers -.-
They give me a headache.Can someone post some helping hints?Oh yeah.I tryed to make,for example,a info sistem on my map.But it didn't work and I know I did something right but I don't know what it is.I want it to show a random message from 20 to 20 seconds of the game.

How do you have problems with basic numbers?

And you know you did something right? I think you mean wrong.

You want to show a message from 20 seconds in the game to 20 seconds in (essentially 0 seconds)?

Why don't you post what you have so far?
 
Level 16
Joined
Oct 30, 2004
Messages
1,277
To create this info system you need a string type variable array 20. Lets name it "hints"

Then you create a trigger:

event - map iniziliation
conditions - none
actions:
-Set variable hints[1] = "Hello all!"
-Set variable hints[2] = "Hello again, did you miss me?"
-Set variable hints[3] = "Running out of things to say"
-Set variable hints[4] = "BURN IN HELL!....joking :)"
etc.

Do that for all the 20 tips.

Then create the trigger that displays your hints:

event - every 20 second of game time
condition - none
actions:
- Game text message: Display hints[random number between 1 and 20] for all players for 15 seconds.

Done! Have fun.
 
Level 8
Joined
Feb 10, 2006
Messages
466
The Integers consist of the positive natural numbers (1, 2, 3, …), their negatives (−1, −2, −3, ...) and the number zero. More formally, the integers are the only integral domain whose positive elements are well-ordered, and in which order is preserved by addition. Like the natural numbers, the integers form a countably infinite set. The set of all integers is usually denoted in mathematics by a boldface Z, which stands for Zahlen (German for "numbers").
 
Status
Not open for further replies.
Top