forked from acegiak/qudkissing
-
Notifications
You must be signed in to change notification settings - Fork 0
/
KissingAmorousPreference.cs
37 lines (29 loc) · 1.01 KB
/
KissingAmorousPreference.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
using System;
using System.Collections.Generic;
using XRL.Core;
using XRL.UI;
namespace XRL.World.Parts
{
[Serializable]
public class acegiak_AmorousPreference : acegiak_KissingPreference
{
float Amount = 0.1f;
public acegiak_AmorousPreference(GameObject GO){
Random random = new Random();
this.Amount = (float)((random.NextDouble()*1.5)-1);
}
public override acegiak_KissingPreferenceResult attractionAmount(GameObject kissee, GameObject GO){
string explain = ((Amount>0)?"is generally amorous":"is &rnot very amorous");
string reactPath = "amorous";
return new acegiak_KissingPreferenceResult(Amount,explain,reactPath);
}
public override void Save(SerializationWriter Writer){
base.Save(Writer);
Writer.Write(Amount);
}
public override void Load(SerializationReader Reader){
base.Load(Reader);
this.Amount = Reader.ReadSingle();
}
}
}