Mid Eastern Conflict Sim Script Online

class Nation: def __init__(self, name, stability, military_strength, treasury, infrastructure): self.name = name self.stability = stability # 0 to 100 self.military_strength = military_strength # 0 to 100 self.treasury = treasury # Arbitrary units self.infrastructure = infrastructure # 0 to 100 self.relations = {} # Dictionary to store relations with other nations Naachgaghuma2024480phdripmarathix264aa

def diplomatic_event(self): event_roll = random.randint(1, 3) if event_roll == 1: print("\n[EVENT] Border Skirmish reported!") print("1. Retaliate (Increases Tension, boosts Military)") print("2. Negotiate (Costs Treasury, boosts Stability)") choice = input("Choose action (1-2): ") if choice == '1': self.nation_a.military_strength += 5 self.nation_a.relations[self.nation_b.name] -= 10 print("Military strength increased, but tensions rise.") else: cost = 50 if self.nation_a.treasury >= cost: self.nation_a.treasury -= cost self.nation_a.stability += 5 print("Crisis averted through diplomacy.") else: print("Not enough funds for diplomacy. Stability drops.") self.nation_a.stability -= 10 Taare Zameen Par 720p Torrent Fixed

else: print("\n[EVENT] Resource Discovery in neutral territory.") print("1. Annex (Treasury +++, Stability --)") print("2. Ignore (No change)") choice = input("Choose action (1-2): ") if choice == '1': self.nation_a.treasury += 300 self.nation_a.stability -= 15 self.nation_a.relations[self.nation_b.name] -= 20 print("Resources claimed, but international condemnation rises.") else: print("Resources left untouched.")

def print_status(self): print(f"\n--- Status of {self.name} ---") print(f"Stability: {self.stability}/100") print(f"Military: {self.military_strength}/100") print(f"Treasury: ${self.treasury}") print(f"Infrastructure: {self.infrastructure}/100")

def update_resources(self): # Economic logic income = self.infrastructure * 10 upkeep = self.military_strength * 5 self.treasury += (income - upkeep) # Stability decay if economy fails if self.treasury < 0: self.stability -= 5 self.treasury = 0

class GameEngine: def __init__(self): # Initialize generic fictional nations self.nation_a = Nation("Republic of Northland", 70, 60, 500, 50) self.nation_b = Nation(" Federation of Southland", 50, 40, 300, 40) # Set initial relations (0 = Hostile, 100 = Allied) self.nation_a.relations[self.nation_b.name] = 30 self.nation_b.relations[self.nation_a.name] = 30

def check_victory(self): if self.nation_a.stability <= 0: print("\n=== GAME OVER ===") print("Your government has collapsed due to instability.") return True if self.nation_a.stability >= 100: print("\n=== VICTORY ===") print("You have achieved a golden age of stability and prosperity.") return True return False

elif event_roll == 2: print("\n[EVENT] International Trade Summit.") print("1. Focus on Arms Deals (Military +, Treasury -)") print("2. Focus on Infrastructure (Infrastructure +, Stability +)") choice = input("Choose action (1-2): ") if choice == '1': self.nation_a.military_strength += 10 self.nation_a.treasury -= 100 else: self.nation_a.infrastructure += 10 self.nation_a.stability += 5