enter into the VB code window in advanced in one of the first frames to set the game up--(i have it in my title frame properties/advanced/vbcode window)
- Code: Select all
Lord_Farley = 0
Lady_Farley = 0
Bishop_Tracepe = 0
Archie_Borld = 0
George_Cant = 0
Margarie_Sene = 0
Cisile_Frankes = 0
Billingsgate = 0
Sir_Margrete_Hill = 0
Advocate_senior = 0
Mary_Cant = 0
Lord_Farley1 = 0
Lady_Farley1 = 0
Bishop_Tracepe1 = 0
Archie_Borld1 = 0
George_Cant1 = 0
Margarie_Sene1 = 0
Cisile_Frankes1 = 0
Billingsgate1 = 0
Sir_Margrete_Hill1 = 0
Advocate_senior1 = 0
Mary_Cant1 = 0
randomize
Dice = int(rnd*(11-1+1))+1
If Dice = 1 Then
Lord_Farley = 1
ElseIf Dice = 2 Then
Lady_Farley = 1
ElseIf Dice = 3 Then
Bishop_Tracepe = 1
ElseIf Dice = 4 Then
Archie_Borld = 1
ElseIf Dice = 5 Then
George_Cant = 1
ElseIf Dice = 6 Then
Margarie_Sene = 1
ElseIf Dice = 7 Then
Cisile_Frankes = 1
ElseIf Dice = 8 Then
Billingsgate = 1
ElseIf Dice = 9 Then
Sir_Margrete_Hill = 1
ElseIf Dice = 10 Then
Advocate_senior = 1
ElseIf Dice = 11 Then
Mary_Cant = 1
Else
Message "NILL."
End If
If Lord_Farley = 1 Then
randomize
Dice1 = int(rnd*(10-1+1))+1
ElseIf Lady_Farley = 1 Then
randomize
Dice2 = int(rnd*(10-1+1))+1
ElseIf Bishop_Tracepe = 1 Then
randomize
Dice3 = int(rnd*(10-1+1))+1
ElseIf Archie_Borld = 1 Then
randomize
Dice4 = int(rnd*(10-1+1))+1
ElseIf George_Cant = 1 Then
randomize
Dice5 = int(rnd*(10-1+1))+1
ElseIf Margarie_Sene = 1 Then
randomize
Dice6 = int(rnd*(10-1+1))+1
ElseIf Cisile_Frankes = 1 Then
randomize
Dice7 = int(rnd*(10-1+1))+1
ElseIf Billingsgate = 1 Then
randomize
Dice8 = int(rnd*(10-1+1))+1
ElseIf Sir_Margrete_Hill = 1 Then
randomize
Dice9 = int(rnd*(10-1+1))+1
ElseIf Advocate_senior = 1 Then
randomize
Dice10 = int(rnd*(10-1+1))+1
ElseIf Mary_Cant = 1 Then
randomize
Dice11 = int(rnd*(10-1+1))+1
Else
Message "NILL 1."
End If
If Dice1 = 1 Then
Mary_Cant1 = 1
ElseIf Dice1 = 2 Then
Lady_Farley1 = 1
ElseIf Dice1 = 3 Then
Bishop_Tracepe1 = 1
ElseIf Dice1 = 4 Then
Archie_Borld1 = 1
ElseIf Dice1 = 5 Then
George_Cant1 = 1
ElseIf Dice1 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice1 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice1 = 8 Then
Billingsgate1 = 1
ElseIf Dice1 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice1 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL1."
End If
If Dice2 = 1 Then
Lord_Farley1 = 1
ElseIf Dice2 = 2 Then
Mary_Cant1 = 1
ElseIf Dice2 = 3 Then
Bishop_Tracepe1 = 1
ElseIf Dice2 = 4 Then
Archie_Borld1 = 1
ElseIf Dice2 = 5 Then
George_Cant1 = 1
ElseIf Dice2 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice2 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice2 = 8 Then
Billingsgate1 = 1
ElseIf Dice2 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice2 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL2."
End If
If Dice3 = 1 Then
Lord_Farley1 = 1
ElseIf Dice3 = 2 Then
Lady_Farley1 = 1
ElseIf Dice3 = 3 Then
Mary_Cant1 = 1
ElseIf Dice3 = 4 Then
Archie_Borld1 = 1
ElseIf Dice3 = 5 Then
George_Cant1 = 1
ElseIf Dice3 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice3 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice3 = 8 Then
Billingsgate1 = 1
ElseIf Dice3 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice3 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL3."
End If
If Dice4 = 1 Then
Lord_Farley1 = 1
ElseIf Dice4 = 2 Then
Lady_Farley1 = 1
ElseIf Dice4 = 3 Then
Mary_Cant1 = 1
ElseIf Dice4 = 4 Then
Bishop_Tracepe1 = 1
ElseIf Dice4 = 5 Then
George_Cant1 = 1
ElseIf Dice4 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice4 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice4 = 8 Then
Billingsgate1 = 1
ElseIf Dice4 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice4 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL4."
End If
If Dice5 = 1 Then
Lord_Farley1 = 1
ElseIf Dice5 = 2 Then
Lady_Farley1 = 1
ElseIf Dice5 = 3 Then
Bishop_Tracepe1 = 1
ElseIf Dice5 = 4 Then
Archie_Borld1 = 1
ElseIf Dice5 = 5 Then
Mary_Cant1 = 1
ElseIf Dice5 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice5 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice5 = 8 Then
Billingsgate1 = 1
ElseIf Dice5 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice5 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL5."
End If
If Dice6 = 1 Then
Lord_Farley1 = 1
ElseIf Dice6 = 2 Then
Lady_Farley1 = 1
ElseIf Dice6 = 3 Then
Bishop_Tracepe1 = 1
ElseIf Dice6 = 4 Then
Archie_Borld1 = 1
ElseIf Dice6 = 5 Then
George_Cant1 = 1
ElseIf Dice6 = 6 Then
Mary_Cant1 = 1
ElseIf Dice6 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice6 = 8 Then
Billingsgate1 = 1
ElseIf Dice6 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice6 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL6."
End If
If Dice7 = 1 Then
Lord_Farley1 = 1
ElseIf Dice7 = 2 Then
Lady_Farley1 = 1
ElseIf Dice7 = 3 Then
Bishop_Tracepe1 = 1
ElseIf Dice7 = 4 Then
Archie_Borld1 = 1
ElseIf Dice7 = 5 Then
George_Cant1 = 1
ElseIf Dice7 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice7 = 7 Then
Mary_Cant1 = 1
ElseIf Dice7 = 8 Then
Billingsgate1 = 1
ElseIf Dice7 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice7 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL7."
End If
If Dice8 = 1 Then
Lord_Farley1 = 1
ElseIf Dice8 = 2 Then
Lady_Farley1 = 1
ElseIf Dice8 = 3 Then
Bishop_Tracepe1 = 1
ElseIf Dice8 = 4 Then
Archie_Borld1 = 1
ElseIf Dice8 = 5 Then
George_Cant1 = 1
ElseIf Dice8 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice8 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice8 = 8 Then
Mary_Cant1 = 1
ElseIf Dice8 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice8 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL8."
End If
If Dice9 = 1 Then
Lord_Farley1 = 1
ElseIf Dice9 = 2 Then
Lady_Farley1 = 1
ElseIf Dice9 = 3 Then
Bishop_Tracepe1 = 1
ElseIf Dice9 = 4 Then
Archie_Borld1 = 1
ElseIf Dice9 = 5 Then
George_Cant1 = 1
ElseIf Dice9 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice9 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice9 = 8 Then
Billingsgate1 = 1
ElseIf Dice9 = 9 Then
Mary_Cant1 = 1
ElseIf Dice9 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL9."
End If
If Dice10 = 1 Then
Lord_Farley1 = 1
ElseIf Dice10 = 2 Then
Lady_Farley1 = 1
ElseIf Dice10 = 3 Then
Bishop_Tracepe1 = 1
ElseIf Dice10 = 4 Then
Archie_Borld1 = 1
ElseIf Dice10 = 5 Then
George_Cant1 = 1
ElseIf Dice10 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice10 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice10 = 8 Then
Billingsgate1 = 1
ElseIf Dice10 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice10 = 10 Then
Mary_Cant1 = 1
Else
Message "NILL10."
End If
If Dice11 = 1 Then
Lord_Farley1 = 1
ElseIf Dice11 = 2 Then
Lady_Farley1 = 1
ElseIf Dice11 = 3 Then
Bishop_Tracepe1 = 1
ElseIf Dice11 = 4 Then
Archie_Borld1 = 1
ElseIf Dice11 = 5 Then
George_Cant1 = 1
ElseIf Dice11 = 6 Then
Margarie_Sene1 = 1
ElseIf Dice11 = 7 Then
Cisile_Frankes1 = 1
ElseIf Dice11 = 8 Then
Billingsgate1 = 1
ElseIf Dice11 = 9 Then
Sir_Margrete_Hill1 = 1
ElseIf Dice11 = 10 Then
Advocate_senior1 = 1
Else
Message "NILL11."
End If
to check it's working correctly create a hot spot
and enter this into the advanced VB code window
the murder victim
- Code: Select all
If Lord_Farley = 1 Then
Message "Lord Farley has been found murdered."
ElseIf Lady_Farley = 1 Then
Message "Lady Farley has been found murdered."
ElseIf Bishop_Tracepe = 1 Then
Message "Bishop Trancepe has been found murdered."
ElseIf Archie_Borld = 1 Then
Message "Archie Borld has been found murdered."
ElseIf George_Cant = 1 Then
Message "George Cant has been found murdered."
ElseIf Margarie_Sene = 1 Then
Message "Margarie Sene has been found murdered."
ElseIf Cisile_Frankes = 1 Then
Message "Cisile Frankes has been found murdered."
ElseIf Billingsgate = 1 Then
Message "Billingsgate has been found murdered."
ElseIf Sir_Margrete_Hill Then
Message "Sir Margrete Hill has been found murdered."
ElseIf Advocate_senior = 1 Then
Message " the Advocate Senior has been found murdered."
ElseIf Mary_Cant = 1 Then
Message "Mary Cant has been found murdered."
Else
Message "all variables nil."
End If
and this into another hotspot same method--
the villian
- Code: Select all
If Lord_Farley1 = 1 Then
Message "Lord Farley has been found guilty."
ElseIf Lady_Farley1 = 1 Then
Message "Lady Farley has been found guilty."
ElseIf Bishop_Tracepe1 = 1 Then
Message "Bishop Trancepe has been found guilty."
ElseIf Archie_Borld1 = 1 Then
Message "Archie Borld has been found guilty."
ElseIf George_Cant1 = 1 Then
Message "George Cant has been found guilty."
ElseIf Margarie_Sene1 = 1 Then
Message "Margarie Sene has been found guilty."
ElseIf Cisile_Frankes1 = 1 Then
Message "Cisile Frankes has been found guilty."
ElseIf Billingsgate1 = 1 Then
Message "Billingsgate has been found guilty."
ElseIf Sir_Margrete_Hill1 Then
Message "Sir Margrete Hill has been found guilty."
ElseIf Advocate_senior1 = 1 Then
Message " the Advocate Senior has been found guilty."
ElseIf Mary_Cant1 = 1 Then
Message "Mary Cant has been found guilty."
Else
Message "all variables nil."
End If
you will need two variant variables for each character
entered into the Global variables window
menu option VBS Variables (advanced)
like so
Lord_Farley
Lady_Farley
Bishop_Tracepe
Archie_Borld
George_Cant
Margarie_Sene
Cisile_Frankes
Billingsgate
Sir_Margrete_Hill
Advocate_senior
Mary_Cant
Lord_Farley1
Lady_Farley1
Bishop_Tracepe1
Archie_Borld1
George_Cant1
Margarie_Sene1
Cisile_Frankes1
Billingsgate1
Sir_Margrete_Hill1
Advocate_senior1
Mary_Cant1
and
11 Dice variant variables in the same global window
Dice
Dice1
Dice2
Dice3
etc
it randomly selects a victim then randomly selects the Villian via a cunning plan (lol) that means the victim cannot be selected as the Villian
(touch wood)
each character has it's own specific Dice variable that is only used if he is selected as victim and it's this dice that choses the villian if you see what i mean
anyhuw--
you can then use this particular dice variable to control the items messages go to fram actions in a custom way for each character
or use the character name variable as i have done to display the name of the victim and murderer on screen
using things like
ie if the murderer is Lord Farley then go to frame1
if it's Lady Farley then go to frame 1b
and so on
could be hotspots turned on and of or diferent items items given --anything
in this way you can use the same variables to give the player clues as to the identity of the villian next time you play the victim, villian AND the clues will be different-and so on--i'm assured the save game option over rides this so you ca safely save your progress mid game and re-load retaining the same crime
- Code: Select all
If Lord_Farley1 = 1 Then
Action.GoToFrame "Frame1"
ElseIf Lady_Farley1 = 1 Then
Action.GoToFrame "Frame1a"
ElseIf Bishop_Tracepe1 = 1 Then
Action.GoToFrame "Frame1c"
ElseIf Archie_Borld1 = 1 Then
Action.GoToFrame "Frame1d"
ElseIf George_Cant1 = 1 Then
Action.GoToFrame "Frame1e"
ElseIf Margarie_Sene1 = 1 Then
Action.GoToFrame "Frame1f"
ElseIf Cisile_Frankes1 = 1 Then
Action.GoToFrame "Frame1g"
ElseIf Billingsgate1 = 1 Then
Action.GoToFrame "Frame1h"
ElseIf Sir_Margrete_Hill1 Then
Action.GoToFrame "Frame1i"
ElseIf Advocate_senior1 = 1 Then
Action.GoToFrame "Frame1j"
ElseIf Mary_Cant1 = 1 Then
Action.GoToFrame "Frame1k"
Else
Message "all variables nil."
End If
(the else "all variables nil" message acts as an error check)
each time you start the game (with the code in the initial frame)
the victim and villian will be different