Jump to content


Photo

Theme: Light


  • Please log in to reply
45 replies to this topic

#41 xiongmao

xiongmao
  • Members
  • 175 posts
  • Location:Paris

Posted 29 February 2008 - 08:04 AM

Yeap Sir ;)

If I'm not wrong it looks like a LinkedList as GameModifiers Field in GameInfo is also a GameRule.

My question is: Why not maintaining a vector of GameRules and loop on this vector when a method of the GameRule must be called ??

It doesn't matter just need to pay attention to "Mutator Compatibility" next time ;)

#42 ambershee

ambershee

    Nimbusfish Rawks

  • Hosted
  • 3,114 posts
  • Location:Derby, UK
  • Projects:Mutator Week & Unreal 3 Projects
  •  Mad Mod Boffin

Posted 29 February 2008 - 09:57 AM

Eh, a vector? That makes no sense to me. A linked list however makes a lot of sense.

#43 xiongmao

xiongmao
  • Members
  • 175 posts
  • Location:Paris

Posted 29 February 2008 - 10:11 AM

Sorry I always think in Java Vector = List = Array ;)

Wow I just take a look at MoDB, you add 4 tutorials !! Do you sleep sometimes or do you work on this all day ? :o

#44 ambershee

ambershee

    Nimbusfish Rawks

  • Hosted
  • 3,114 posts
  • Location:Derby, UK
  • Projects:Mutator Week & Unreal 3 Projects
  •  Mad Mod Boffin

Posted 29 February 2008 - 11:15 AM

I haven't slept. I had to work late, and while code was compiling / meshes were exporting, I worked on getting tutorials into that lousy text editor. I'm still at work now, I could really do with a nap.

But, right now I'm tying to work out how to generate a random number in UnrealScript instead..

Edited by ambershee, 29 February 2008 - 11:16 AM.


#45 xiongmao

xiongmao
  • Members
  • 175 posts
  • Location:Paris

Posted 29 February 2008 - 11:40 AM

Not sure to understand, what is random number ??

you got two methods in Object class which do this:

native(167) static final function int Rand ( int Max ) Rand will give you a value between 0 and Max -1

static final simulated function float RandRange ( float InMin, float InMax ) ) Return a random number within the given range.

#46 ambershee

ambershee

    Nimbusfish Rawks

  • Hosted
  • 3,114 posts
  • Location:Derby, UK
  • Projects:Mutator Week & Unreal 3 Projects
  •  Mad Mod Boffin

Posted 29 February 2008 - 01:30 PM

Not sure to understand, what is random number ??

A number generated at random - like rolling a dice for example, you don't know what number you will get.

native(167) static final function int Rand ( int Max ) Rand will give you a value between 0 and Max -1


Only useful if you have two or three options.

static final simulated function float RandRange ( float InMin, float InMax ) ) Return a random number within the given range.


I'm using this at present. I also use % GameTime to do some other number generating too.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users